<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
	<title>jQuery Grid Plugin - jqGrid - Topic: HOW TO? Display results of editoptions dataUrl with form editing?</title>
	<link>http://www.trirand.com/blog/?page_id=393/help/how-to-display-results-of-editoptions-dataurl-with-form-editing</link>
	<description><![CDATA[Grid plugin]]></description>
	<generator>Simple:Press Version 5.7.5.3</generator>
	<atom:link href="http://www.trirand.com/blog/?page_id=393/help/how-to-display-results-of-editoptions-dataurl-with-form-editing/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>Trober on HOW TO? Display results of editoptions dataUrl with form editing?</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/how-to-display-results-of-editoptions-dataurl-with-form-editing#p20314</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/how-to-display-results-of-editoptions-dataurl-with-form-editing#p20314</guid>
        	        	<description><![CDATA[<p>Seems noone knows. ??? &#160;</p>
<p>3 of 4 posts I have no answer on this forum. &#160;<img class="spSmiley" style="margin:0" title="Frown" src="/blog/wp-content/forum-smileys/sf-frown.gif" alt="Frown" /></p>
]]></description>
        	        	<pubDate>Fri, 15 Oct 2010 08:35:16 +0300</pubDate>
        </item>
        <item>
        	<title>bhneto on HOW TO? Display results of editoptions dataUrl with form editing?</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/how-to-display-results-of-editoptions-dataurl-with-form-editing#p20194</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/how-to-display-results-of-editoptions-dataurl-with-form-editing#p20194</guid>
        	        	<description><![CDATA[<p>Hi</p>
<p>I have a similar problem as u. I want to get a list of a SELECT through a .php and this list would to fill the editoptions of a select type.</p>
<p>My is here:</p>
<p>&#160;&#160;&#160; $(document).ready(function(){<br />&#160;&#160; &#160;jQuery("#tabAreaCompetencia").jqGrid({<br />&#160;&#160; &#160;&#160;&#160;&#160;&#160;&#160; url:&#39;areasConhecimento.php&#39;,<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160; datatype: "xml",<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160; colNames:[&#39;C&#243;digo&#39;,&#39;&#193;rea Conhecimento&#39;, &#39;C&#243;digo&#39;, &#39;Compet&#234;ncia&#39;],<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160; colModel:[<br />&#160;&#160; &#160;&#160;&#160; &#160; &#160;&#160;&#160; &#160;{name:&#39;codArea1&#39;,index:&#39;codArea1&#39;, width:100,editable:true, editrules: { edithidden: true}},<br />&#160;&#160; &#160;&#160;&#160; &#160; &#160;&#160;&#160; &#160;{name:&#39;areaConhecimento1&#39;,index:&#39;areaConhecimento1&#39;, width:150, editable:true, edittype:"select", editoptions:{value:"1:one;2:two"}},<br />&#160;&#160; &#160;&#160;&#160; &#160; &#160;&#160;&#160; &#160;{name:&#39;codCompetencia1&#39;,index:&#39;codCompetencia1&#39;, width:100,editable:true,editrules: { edithidden: false}},<br />&#160;&#160; &#160;&#160;&#160; &#160; &#160;&#160;&#160; &#160;{name:&#39;competencia1&#39;,index:&#39;competencia1&#39;, width:100,editable:true,edittype:"select", editoptions: { dataUrl : &#39;{areasConhecimento.php}&#39; }},<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160; ],<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160; rowNum:10,<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160; rowList:[10,20,30],<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160; pager: &#39;#pagered&#39;,<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160; sortname: &#39;areaConhecimento&#39;,<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160; viewrecords: true,<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160; sortorder: "desc",<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160; caption:"&#193;reas de Conhecimento e Compet&#234;ncias",<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160; editurl:"areasConhecimento.php"<br />&#160;&#160; &#160;});</p>
<p>The column name &#39;competencia1&#39; call .php... And the .php code is:</p>
<p>$sql = "SELECT conceito_id, descricao FROM area_conhecimento ORDER BY descricao ASC";<br />$res = mysql_query($sql);<br />$qtdeLinhas = mysql_num_rows($res);<br />$qtdeLinhas = $qtdeLinhas-1;<br />for ($i=0; $i&#60;$qtdeLinhas; $i++){<br />&#160;&#160; &#160;$registro = mysql_fetch_row($res);<br />&#160;&#160; &#160;$cod = $registro[0];<br />&#160;&#160; &#160;$nome = $registro[1];<br />&#160;&#160; &#160;if ($i != $qtdeLinhas){<br />&#160;&#160; &#160;&#160;&#160; &#160;$resultado = $cod .":". $nome .";";<br />&#160;&#160; &#160;}<br />&#160;&#160; &#160;if ($i == $qtdeLinhas){<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;$resultado = $cod .":". $nome ."" ;<br />&#160;&#160; &#160;}<br />&#160;&#160; &#160;echo $resultado;&#160;</p>
<p>}</p>
<p>I imagine that the variable $resultado should return the string in this format: &#8220;FE:FedEx; IN:InTime; TN:TNT&#8221;. But unfortunately, it doesn&#39;t work.</p>
</p>
<p>I already have tried using ajax this way:</p>
<p>Instead of : editoptions: { dataUrl : &#39;{areasConhecimento.php}&#39; }, I tried: editoptions: {value:obterAreaConhecimento()}. In the code .php I get the list with this line:</p>
<p>&#160;&#160;&#160; $_POST[&#39;text&#39;] = $resultado;</p>
<p>The function is:</p>
<p>&#160;&#160;&#160; function obterAreaConhecimento(){<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;urlConsultaArea = "./areasConhecimento.php";&#160;&#160; <br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;$.ajax({<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;type: &#160;&#160; &#160;&#160;&#160; &#160;"get",<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;url: &#160;&#160; &#160;&#160;&#160; &#160;urlConsultaArea,<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;dataType: &#160;&#160; &#160;"text",<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;success: &#160;&#160; &#160;function(text){concatenaString(text)}<br />&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;})<br />&#160;&#160; &#160;}<br />&#160;&#160;&#160; function concatenaString(text){<br />&#160;&#160; &#160;&#160;&#160; &#160;alert(text);<br />&#160;&#160; &#160;&#160;&#160; &#160;var editoptions = text;&#160;&#160; &#160;&#160;&#160; &#160;&#160;&#160; &#160;<br />&#160;&#160; &#160;&#160;&#160; &#160;alert(editoptions);<br />&#160;&#160; &#160;&#160;&#160; &#160;if (editoptions != ""){<br />&#160;&#160; &#160;&#160;&#160; &#160;return editoptions;&#160;&#160; &#160;<br />&#160;&#160; &#160;&#160;&#160; &#160;}&#160;&#160; &#160;<br />&#160;&#160; &#160;}</p>
<p>Alert shows the string with strange characters (6.02.00.00-6:Administraï¿½ï¿½o;6.02.01.00-2:Administraï¿½ï¿½o de Empresas;6.02.03.00-5:Administraï¿½ï¿½o de Setores Espec) and the select in the grid remains empty.</p>
<p>So, these 2 forms doesn&#39;t work yet.</p>
<p>How did you do? Maybe can we help each other.</p>
</p>
<p>[]`s</p>
]]></description>
        	        	<pubDate>Thu, 07 Oct 2010 21:36:38 +0300</pubDate>
        </item>
        <item>
        	<title>Trober on HOW TO? Display results of editoptions dataUrl with form editing?</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/how-to-display-results-of-editoptions-dataurl-with-form-editing#p20181</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/how-to-display-results-of-editoptions-dataurl-with-form-editing#p20181</guid>
        	        	<description><![CDATA[<p>Noone knows or has answer?</p>
]]></description>
        	        	<pubDate>Wed, 06 Oct 2010 23:55:32 +0300</pubDate>
        </item>
        <item>
        	<title>Trober on HOW TO? Display results of editoptions dataUrl with form editing?</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/how-to-display-results-of-editoptions-dataurl-with-form-editing#p20069</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/how-to-display-results-of-editoptions-dataurl-with-form-editing#p20069</guid>
        	        	<description><![CDATA[<p>If editoptions dataUrl have problem how can server response &#160;be displayed &#160;on form editing?</p>
<p>Some times, server respond with message to user which is not ajax error.</p>
<p>errorTextFormat event not fired.</p>
<p>afterSubmit too late.</p>
<p>documentations we haven&#39;t found an event with server response we can display on bottominfo for example.</p>
</p>
<p>hope someone helps. &#160;last message no one did. &#160; <img class="spSmiley" style="margin:0" title="Cry" src="/blog/wp-content/forum-smileys/sf-cry.gif" alt="Cry" /></p>
</p>
<p>thanks</p>
]]></description>
        	        	<pubDate>Wed, 29 Sep 2010 13:50:04 +0300</pubDate>
        </item>
</channel>
</rss>