<?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: &#091; 3.8  - bug &#093; - Update table with a json string</title>
	<link>http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string</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/bugs/3-8-bug-update-table-with-a-json-string/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>jacquesh on &#091; 3.8  - bug &#093; - Update table with a json string</title>
        	<link>http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20119</link>
        	<category>Bugs</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20119</guid>
        	        	<description><![CDATA[<p>OK, I&#39;ve add a cell, change the form of jsonstring ; but the problem still the same.</p>
</p>
<p><input type='button' class='sfcodeselect' name='sfselectit5667' value='Select Code' data-codeid='sfcode5667' /></p>
<div class='sfcode' id='sfcode5667'>
<p>var mystr = &#39;{&#34;total&#34;: &#34;1&#34;,&#34;page&#34;: &#34;1&#34;,&#34;records&#34;: &#34;1&#34;,&#34;rows&#34; : [{&#34;id&#34;:&#34;1&#34;, &#34;cell&#34;:[&#34;cell00711&#34;,&#34;cell00711&#34;,&#34;cell12&#34;,&#34;cell13&#34;,&#34;cell12&#34;,&#34;cell13&#34;]}]}&#39;;</p>
<p>jQuery(&#34;#process_list&#34;)</p>
<p>.jqGrid(&#34;setGridParam&#34;, {datastr:mystr})</p>
<p>.trigger(&#34;reloadGrid&#34;);</p>
</div>
<p>&#160;Everything is OK via json(URL) but not with json(string)</p>
<p>Can you try to create a mini sample with a grid with new data when reloading with jsonstring as datatype.</p>
<p>I&#39;d like to see a worked sample to be sure it&#39;s not a bug <img class="spSmiley" style="margin:0" title="Embarassed" src="/blog/wp-content/forum-smileys/sf-embarassed.gif" alt="Embarassed" /></p>
</p>
<p>Thanks !</p>
]]></description>
        	        	<pubDate>Sun, 03 Oct 2010 01:42:07 +0300</pubDate>
        </item>
        <item>
        	<title>OlegK on &#091; 3.8  - bug &#093; - Update table with a json string</title>
        	<link>http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20096</link>
        	<category>Bugs</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20096</guid>
        	        	<description><![CDATA[<p>Moveover&#160;<strong>jacquesh</strong>&#160;you have to follow JavaScript syntax. If a string has " and you use ans " for the string definition you should escape there: ". Better to define mystr using single quote as:</p>
</p>
<p><input type='button' class='sfcodeselect' name='sfselectit9551' value='Select Code' data-codeid='sfcode9551' /></p>
<div class='sfcode' id='sfcode9551'>var mystr = &#39;{&#34;total&#34;: &#34;1&#34;,&#34;page&#34;: &#34;1&#34;,&#34;records&#34;: &#34;1&#34;,&#34;rows&#34; : [{&#34;id&#34;:&#34;1&#34;, &#34;cell&#34;:[&#34;cell00711&#34;,&#34;cell12&#34;,&#34;cell13&#34;,&#34;cell12&#34;,&#34;cell13&#34;]}]}&#39;;</div>
<p>Regards<br />Oleg&#160;</p>
]]></description>
        	        	<pubDate>Fri, 01 Oct 2010 11:46:05 +0300</pubDate>
        </item>
        <item>
        	<title>tony on &#091; 3.8  - bug &#093; - Update table with a json string</title>
        	<link>http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20092</link>
        	<category>Bugs</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20092</guid>
        	        	<description><![CDATA[<p>Hello,</p>
<p>In your case you have set 5 records, but your definition in colModel has 6 fields.</p>
<p>Pleadse read this carefully:</p>
<p><a href="http://www.trirand.com/jqgridwiki/doku.php?id=wiki:retrieving_data#json_data" rel="nofollow" target="_blank"><a href="http://www.trirand.com/jqgridw" rel="nofollow">http://www.trirand.com/jqgridw</a>.....#json_data</a></p>
</p>
<p>Regards</p>
]]></description>
        	        	<pubDate>Fri, 01 Oct 2010 09:07:06 +0300</pubDate>
        </item>
        <item>
        	<title>jacquesh on &#091; 3.8  - bug &#093; - Update table with a json string</title>
        	<link>http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20090</link>
        	<category>Bugs</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20090</guid>
        	        	<description><![CDATA[<p>my jqGrid definition</p>
<p><input type='button' class='sfcodeselect' name='sfselectit6808' value='Select Code' data-codeid='sfcode6808' /></p>
<div class='sfcode' id='sfcode6808'>
<p>$(&#34;#process_list&#34;).jqGrid({</p>
<p>datatype: &#39;jsonstring&#39;,</p>
<p>datastr: mystr,</p>
<p>colNames:[&#39;id&#39;,&#39;Pid&#39;,&#39;PPid&#39;, &#39;Name&#39;, &#39;Path&#39;,&#39;CmdLine&#39;],</p>
<p>colModel:[</p>
<p>{name:&#39;id&#39;,		index:&#39;id&#39;, 	width:0},</p>
<p>{name:&#39;pid&#39;,	index:&#39;pid&#39;, 	width:50},</p>
<p>{name:&#39;ppid&#39;,	index:&#39;ppid&#39;, 	width:50},</p>
<p>{name:&#39;name&#39;,	index:&#39;name&#39;, 	width:150},</p>
<p>{name:&#39;path&#39;,	index:&#39;path&#39;, 	width:250},</p>
<p>{name:&#39;cmdline&#39;,index:&#39;cmdline&#39;,width:300}</p>
<p>],</p>
<p>sortname: &#39;pid&#39;,</p>
<p>viewrecords: true,</p>
<p>sortorder: &#34;desc&#34;,</p>
<p>multiselect: false,</p>
<p>caption:&#34;Process list&#34;</p>
<p>});</p>
</div>
]]></description>
        	        	<pubDate>Fri, 01 Oct 2010 01:49:43 +0300</pubDate>
        </item>
        <item>
        	<title>jacquesh on &#091; 3.8  - bug &#093; - Update table with a json string</title>
        	<link>http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20089</link>
        	<category>Bugs</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20089</guid>
        	        	<description><![CDATA[</p>
<p><input type='button' class='sfcodeselect' name='sfselectit3321' value='Select Code' data-codeid='sfcode3321' /></p>
<div class='sfcode' id='sfcode3321'>
<p>mystr = &#34;{\&#34;total\&#34;:\&#34;1\&#34;,\&#34;page\&#34;:\&#34;1\&#34;,\&#34;records\&#34;:\&#34;1\&#34;,\&#34;rows\&#34; : [{\&#34;id\&#34;:\&#34;1\&#34;, \&#34;cell\&#34;:[\&#34;cell00711\&#34;,\&#34;cell12\&#34;,\&#34;cell13\&#34;,\&#34;cell12\&#34;,\&#34;cell13\&#34;]}]}&#34;</p>
<p>jQuery(&#34;#process_list&#34;)</p>
<p>.jqGrid(&#34;setGridParam&#34;, {datastr:mystr})&#160;</p>
<p>.trigger(&#34;reloadGrid&#34;);</p>
</p>
</div>
<p>same problem with a validated string.</p>
<p>Grid reload but with previous data.</p>
<p>another idea ?</p>
]]></description>
        	        	<pubDate>Fri, 01 Oct 2010 01:47:56 +0300</pubDate>
        </item>
        <item>
        	<title>OlegK on &#091; 3.8  - bug &#093; - Update table with a json string</title>
        	<link>http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20088</link>
        	<category>Bugs</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20088</guid>
        	        	<description><![CDATA[<p>Hello!</p>
<p>You used before wrong JSON data. Corresponds to <a href="http://www.json.org/" target="_blank">http://www.json.org/</a>&#160;all strings must be double-quoited:</p>
<p><span style="font-size: 13.8889px;">&#160;</span></p>
<p><input type='button' class='sfcodeselect' name='sfselectit5917' value='Select Code' data-codeid='sfcode5917' /></p>
<div class='sfcode' id='sfcode5917'>
<p>{<br /><span style=&#34;font-size: 13.8889px;&#34;>&#160;&#160;&#34;total&#34;: &#34;1&#34;,<br /><span style=&#34;font-size: 13.8889px;&#34;>&#160;&#160;&#34;page&#34;: &#34;1&#34;,<br /><span style=&#34;font-size: 13.8889px;&#34;>&#160;&#160;&#34;records&#34;: &#34;1&#34;,<br /><span style=&#34;font-size: 13.8889px;&#34;>&#160;&#160;&#34;rows&#34; : [<br /><span style=&#34;font-size: 13.8889px;&#34;>&#160;&#160; &#160;{&#34;id&#34;:&#34;1&#34;, &#34;cell&#34;:[&#34;cell00711&#34;,&#34;cell12&#34;,&#34;cell13&#34;,&#34;cell12&#34;,&#34;cell13&#34;]}<br /><span style=&#34;font-size: 13.8889px;&#34;>&#160;&#160;]<br /><span style=&#34;font-size: 13.8889px;&#34;>}</span></span></span></span></span></span></span></p>
</p>
</div>
<p>So fix your code and it will work. I recommend you validate your JSON data in <a href="http://www.jsonlint.com/" target="_blank">http://www.jsonlint.com/</a>.
</p>
<p>Regards<br />Oleg</p>
]]></description>
        	        	<pubDate>Fri, 01 Oct 2010 00:43:00 +0300</pubDate>
        </item>
        <item>
        	<title>jacquesh on &#091; 3.8  - bug &#093; - Update table with a json string</title>
        	<link>http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20086</link>
        	<category>Bugs</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/bugs/3-8-bug-update-table-with-a-json-string#p20086</guid>
        	        	<description><![CDATA[<p>Hello,&#160;</p>
<p><input type='button' class='sfcodeselect' name='sfselectit4118' value='Select Code' data-codeid='sfcode4118' /></p>
<div class='sfcode' id='sfcode4118'>
<p>mystr =</p>
<p>&#34;{&#34; +</p>
<p>&#34;total: &#39;1&#39;,&#34; +</p>
<p>&#34;page: &#39;1&#39;,&#34; +</p>
<p>&#34;records: &#39;1&#39;,&#34; +</p>
<p>&#34;rows : [&#34; +</p>
<p>&#34;{id:&#39;1&#39;, cell:[&#39;cell00711&#39;,&#39;cell12&#39;,&#39;cell13&#39;,&#39;cell12&#39;,&#39;cell13&#39;]}&#34; +</p>
<p>&#34;]&#34; +</p>
<p>&#34;}&#34;;</p>
</p>
<p>jQuery(&#34;#process_list&#34;)</p>
<p>.jqGrid(&#34;setGridParam&#34;, {datastr:mystr})</p>
<p>.trigger(&#34;reloadGrid&#34;);</p>
</div>
<p>The grid load data with no problem from an URL.</p>
<p>I&#39;ve set&#160;datastr: mystr and datatype: &#39;jsonstring&#39;. No JS error but the grid don&#39;t load new data.</p>
<p>I&#39;ve the same problem with 3.7.</p>
</p>
<p>Any Idea ?</p>
</p>
<p>Thanks for your help.</p></p>
]]></description>
        	        	<pubDate>Thu, 30 Sep 2010 23:31:28 +0300</pubDate>
        </item>
</channel>
</rss>