Note that there are some explanatory texts on larger screens.

plurals
  1. POjquery autocomplete plugin does not submit values to server
    primarykey
    data
    text
    <p>I am using this plugin: <a href="http://jquery.bassistance.de/autocomplete/demo/" rel="nofollow noreferrer">http://jquery.bassistance.de/autocomplete/demo/</a></p> <p>I have an autocomplete textarea where the values are autocompleted and are separated by commas.</p> <p>This textarea is inside a form. When I submit this form, I expect the values to be transmitted to the serverside which is the action of my form. However, I am not getting any values back. </p> <p>How can I fix that?</p> <p>Here is my code:</p> <p>jQuery autocomplete code:</p> <pre><code>jQueryTest("#newImages").autocomplete("images.php", { width: 320, max: 3, highlight: false, scroll: true, scrollHeight: 200, multiple: true, formatItem: function(data, i, n, value) { return "&lt;img height='72' width='72' src='/catalogFiles/" + value + ".jpg'/&gt; " + value.split(".")[0]; }, formatResult: function(data, value) { return value.split(".")[0]; }, }); </code></pre> <p>Html:</p> <pre><code>&lt;form method="post" action="&lt;?= $_SERVER['PHP_SELF'] ?&gt;"&gt; &lt;td style="padding-right: 25px;"&gt;New Images:&lt;/td&gt; &lt;td&gt;&lt;textarea class="inputmeat" name="newImages_name" rows="3" cols="60" id="newImages"&gt;&lt;/textarea&gt;&lt;/td&gt; &lt;td style="padding-right: 25px;"&gt;&lt;/td&gt; &lt;td&gt;&lt;input type="submit" name="cmd" value="Update" /&gt;&lt;/td&gt; &lt;/form&gt; </code></pre> <p>PHP Code when submit is clicked:</p> <pre><code>&lt;?php $cmd=$_POST["cmd"]; if(isset($cmd)) { $newImagesName = mysql_escape_string( $_POST["newImages_name"]); echo $newImageName; } ?&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload