<?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: passing variables to gqgrid</title>
	<link>http://www.trirand.com/blog/?page_id=393/help/passing-variables-to-gqgrid</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/passing-variables-to-gqgrid/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>jemison on passing variables to gqgrid</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/passing-variables-to-gqgrid#p1456</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/passing-variables-to-gqgrid#p1456</guid>
        	        	<description><![CDATA[<p>I found a way!!!</p>
<p>in example.html</p>
<p>&#8230;</p>
<p>&#60;td&#62;&#60;button onclick=&#8221;gridReload()&#8221; id=&#8221;s_search&#8221; style=&#8221;margin-left:30px;&#8221;&#62;Search&#60;/button&#62;&#60;/td&#62;</p>
<p>..</p>
<p>function gridReload(){<br />&#160;&#160;&#160; &#160;&#160; var param1 = jQuery(&#8221;#param1&#8243;).val();<br />&#160;&#160;&#160; &#160;&#160; var param2 = jQuery(&#8221;#param2&#8243;).val();<br />jQuery(&#8221;#list2&#8243;).setGridParam({url:&#8221;example.php?param1=&#8221;+param1+&#8221;&#38;param2=&#8221;+param2,page:1}).trigger(&#8221;reloadGrid&#8221;);}</p>
<p>and, in example.php</p>
<p>$param1 = $_REQUEST[&#39;param1&#39;];</p>
<p>$param2 = $_REQUEST[&#39;param2&#39;];</p></p>
]]></description>
        	        	<pubDate>Sun, 10 Aug 2008 11:05:20 +0300</pubDate>
        </item>
        <item>
        	<title>jemison on passing variables to gqgrid</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/passing-variables-to-gqgrid#p1454</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/passing-variables-to-gqgrid#p1454</guid>
        	        	<description><![CDATA[<p>okay, I followed your instructions, but still can&#39;t get it to work.</p>
<p>I have something like that in example.html:</p>
<p>&#60;script type=&#8221;text/javascript&#8221;&#62;<br />&#160;&#160;&#160;&#160; jQuery(document).ready(function(){<br />&#160;&#160;&#160;&#160; $(&#8221;#s_search&#8221;).click(function(){<br />&#160;&#160;&#160; &#160; &#160; jQuery(&#8221;#list2&#8243;).jqGrid({<br />&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160; url:&#39;example.php?nd=&#39;+new Date().getTime(),</p>
<p>&#160; &#8230;.. }); });});<br />&#60;/script&#62;</p>
<p>&#8230;.<br />&#60;select id=&#8221;param1&#8221; name=&#8221;param1&#8243;&#62;<br />&#60;option value=&#8221;0&#8243; selected=&#8221;selected&#8221;&#62;Search BY&#60;/option&#62;<br />&#60;option value=&#8221;idOrder&#8221;&#62;No&#60;/option&#62;<br />&#60;option value=&#8221;customerName&#8221;&#62;Client name&#60;/option&#62;<br />&#60;option value=&#8221;childName&#8221;&#62;Child Name&#60;/option&#62;<br />&#60;/select&#62;<br />&#60;input type=&#8221;text&#8221; id=&#8221;param2&#8243; name=&#8221;param2&#8243; value=&#8221;"&#62;<br />&#60;input type=&#8221;submit&#8221; name=&#8221;s_search&#8221; id=&#8221;s_search&#8221; value=&#8221;Search&#8221;&#62;</p>
<p>&#60;table id=&#8221;list2&#8243; class=&#8221;scroll&#8221; cellpadding=&#8221;0&#8243; cellspacing=&#8221;0&#8243;&#62;&#60;/table&#62;<br />&#60;!&#8211; pager definition. class scroll tels that we want to use the same theme as grid &#8211;&#62;<br />&#60;div id=&#8221;pager2&#8243; class=&#8221;scroll&#8221; style=&#8221;text-align: center;&#8221;&#62;&#60;/div&#62;<br />&#8230;.</p>
<p>now, how do I get the value of param1 and param2 in example.php?</p></p>
]]></description>
        	        	<pubDate>Sat, 09 Aug 2008 09:17:35 +0300</pubDate>
        </item>
        <item>
        	<title>canvas.wang on passing variables to gqgrid</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/passing-variables-to-gqgrid#p1453</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/passing-variables-to-gqgrid#p1453</guid>
        	        	<description><![CDATA[<p>I just did it. in grid.base.js, do the following:</p>
<p>$.fn.jqGrid = function(p) {</p>
<p>&#160;&#160;&#160; p = $.extend([</p>
<p>&#160;&#160;&#160; ...</p>
<p>&#160;&#160; myParam1: &#39;haha1&#39;&#160;&#160; // default value for my parameter</p>
<p>&#160;&#160; myParam2: &#39;haha2&#39;</p>
<p>&#160;&#160;&#160; ...</p>
<p>&#160;&#160;&#160; ]}</p>
<p>}</p>
</p>
<p>Then look for&#160; the following code in the same javascript file:</p>
<p>var populate = function() {</p>
<p>&#160;&#160;&#160; if (!grid.hDiv.loading) {&#160;&#160;</p>
<p>&#160;&#160;&#160; &#160;&#160;  beginReq();</p>
<p>&#160;&#160;&#160;&#160;&#160;&#160; // modify the following line by adding the two parameters</p>
<p>&#160;&#160;&#160; &#160;&#160;  var&#160; gdata = $.extend(ts.p.postData, (myParam1: ts.p.myParam1, myParam2:&#160; ts.p.myParam2, .....))</p>
<p>&#160;&#160;&#160; &#160;&#160;  ....</p>
<p>&#160;&#160;&#160; }</p>
<p>}</p>
</p>
<p>And then you can use the two parameters. Good luck.</p>
]]></description>
        	        	<pubDate>Fri, 08 Aug 2008 18:32:29 +0300</pubDate>
        </item>
        <item>
        	<title>jemison on passing variables to gqgrid</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/passing-variables-to-gqgrid#p1451</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/passing-variables-to-gqgrid#p1451</guid>
        	        	<description><![CDATA[<p>hello,</p>
<p>Im trying to pass some params to the grid.</p>
<p>Im doing a search tool and&#160;I want to pass 2 params from a dropdown and textfield,&#160;so I can search the DB accordingly.</p>
<p>how do I get thoses values on the server side?</p>
]]></description>
        	        	<pubDate>Fri, 08 Aug 2008 15:00:14 +0300</pubDate>
        </item>
</channel>
</rss>