Note that there are some explanatory texts on larger screens.

plurals
  1. POJQuery Dialog won't enable changing data in text fields
    text
    copied!<p>I have project that shows few tables and try to use JQuery dialog boxes to change and add data to tables. I implemented dialog and the function to show it and populate with content from table works fine. Also save button works nice so I save content to database.</p> <p>My question is when I open dialog my content inside text boxes is not editable. I puted input fields like this:</p> <pre><code>&lt;input type="text" name="codice" id="codice" class="text ui-widget-content ui-corner-all" contenteditable="true" /&gt; </code></pre> <p>Can anyone help me to enalbe editing to those fields. Thanks.</p> <pre><code>&lt;div id="dialog-form" title="Gestione Tipo Appuntamento" &gt; &lt;form id="dialogform" action="agendaTipoAppuntamentoSalvaJson.do" contenteditable="true" &gt; &lt;input type="hidden" name="idTipoAppuntamento" id="idTipoAppuntamento" value="" /&gt; &lt;fieldset&gt;&lt;table&gt; &lt;tr&gt; &lt;td&gt; &lt;label for="codice"&gt;Codice &lt;/label&gt; &lt;/td&gt;&lt;td&gt; &lt;input type="text" name="codice" id="codice" class="text ui-widget-content ui-corner-all" contenteditable="true" /&gt; &lt;/td&gt;&lt;/tr&gt;&lt;tr&gt; &lt;td&gt; &lt;label for="descrizione"&gt;Descrizione &lt;/label&gt; &lt;/td&gt;&lt;td&gt; &lt;input type="text" name="descrizione" id="descrizione" value="" class="text ui-widget-content ui-corner-all" contenteditable="true" /&gt; &lt;/td&gt;&lt;/tr&gt;&lt;tr&gt; &lt;td&gt; &lt;label for="descrBreve"&gt;descrBreve &lt;/label&gt; &lt;/td&gt;&lt;td&gt; &lt;input type="text" name="descrBreve" id="descrBreve" value="" class="text ui-widget-content ui-corner-all" contenteditable="true" /&gt; &lt;/td&gt;&lt;/tr&gt;&lt;tr&gt; &lt;td&gt; &lt;label for="colore"&gt;colore &lt;/label&gt; &lt;/td&gt;&lt;td&gt; &lt;input type="text" name="colore" id="colore" value="" class="text ui-widget-content ui-corner-all" contenteditable="true" /&gt; &lt;/td&gt; &lt;/tr&gt; &lt;/table&gt;&lt;/fieldset&gt; &lt;/form&gt; &lt;/div&gt; </code></pre> <p>and JS part to call variables:</p> <pre><code>function showUpdate(id,codice,descrizione,descrBreve,colore) { $('#idTipoAppuntamento').val(id); $('#codice').val(codice); $('#descrizione').val(descrizione); $('#descrBreve').val(descrBreve); $('#colore').val(colore); $( "#dialog-form" ).dialog( "open" ); } </code></pre>
 

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