Note that there are some explanatory texts on larger screens.

plurals
  1. POStruts2 jquery autocompleter with JSON
    primarykey
    data
    text
    <p>I'm using atocompleter in my form with json. This is the part of my struts.xml</p> <pre><code> &lt;package name="default" extends="struts-default,json-default"&gt; &lt;action name="jsonSample" class="com.jaisar.jsep.product.web.action.DatabaseJSON" method="getDatabaseJSONData" &gt; &lt;result type="json"/&gt; &lt;/action&gt; &lt;/package&gt; </code></pre> <p>My jsp page is :</p> <pre><code>&lt;%@ taglib prefix="s" uri="/struts-tags" %&gt; &lt;%@ taglib prefix="sj" uri="/struts2-jquery-tags"%&gt; &lt;s:url id="remoteurl" action="jsonSample.action"/&gt; &lt;sj:select href="%{remoteurl}" id="echo" name="echo" list="languageList" emptyOption="true" headerKey="-1" headerValue="Please Select a Language"/&gt; </code></pre> <p>Action class method is :</p> <pre><code>public class DatabaseJSON extends ActionSupport { private List&lt;String&gt; languageList; public String getDatabaseJSONData() { languageList = new ArrayList&lt;String&gt;(); languageList.add("Java"); languageList.add("PHP"); languageList.add("C#"); return SUCCESS; } // Setters and getters for languageList .. } </code></pre> <p>But the page doesn't load with the autocompleter. Page shows simply a select box... Any solutions? Plz ... I refered a lot , but i couln't find the silution...</p> <p>I referred the site <a href="http://code.google.com/p/struts2-jquery/wiki/SelectTag#Receive_Entrys_from_a_simple_String_List" rel="nofollow">http://code.google.com/p/struts2-jquery/wiki/SelectTag#Receive_Entrys_from_a_simple_String_List</a> </p> <p>Thanks in advance...</p>
    singulars
    1. This table or related slice is empty.
    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.
 

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