<?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: Set grid caption</title>
	<link>http://www.trirand.com/blog/?page_id=393/feature-request/set-grid-caption</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/feature-request/set-grid-caption/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>nerd on Set grid caption</title>
        	<link>http://www.trirand.com/blog/?page_id=393/feature-request/set-grid-caption#p25001</link>
        	<category>Feature Request</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/feature-request/set-grid-caption#p25001</guid>
        	        	<description><![CDATA[</p>
<p>hi guys,</p>
<p>i want to suggest a new method to set the grid caption with this function (v4.2.0)</p>
</p>
<p>file: grid.base.js (add: id=&#39;"+ts.p.id+"_caption&#39;)</p>
</p>
<p><input type='button' class='sfcodeselect' name='sfselectit7172' value='Select Code' data-codeid='sfcode7172' /></p>
<div class='sfcode' id='sfcode7172'>line 2403: $(grid.cDiv).append(arf).append(&#34;&#60;span class=&#39;ui-jqgrid-title&#34;+(dir==&#34;rtl&#34; ? &#34;-rtl&#34; :&#34;&#34; )+&#34;&#39;&#62;&#34;+ts.p.caption+&#34;&#60;/span&#62;&#34;)</div>
</p>
<p>change by this line</p>
</p>
<p><input type='button' class='sfcodeselect' name='sfselectit978' value='Select Code' data-codeid='sfcode978' /></p>
<div class='sfcode' id='sfcode978'>$(grid.cDiv).append(arf).append(&#34;&#60;span id=&#39;&#34;+ts.p.id+&#34;_caption&#39; class=&#39;ui-jqgrid-title&#34;+(dir==&#34;rtl&#34; ? &#34;-rtl&#34; :&#34;&#34; )+&#34;&#39;&#62;&#34;+ts.p.caption+&#34;&#60;/span&#62;&#34;)</div>
</p>
<p>and</p>
<p>below the line 2505 add this in order to extend the jqgrid API</p>
<p><input type='button' class='sfcodeselect' name='sfselectit5423' value='Select Code' data-codeid='sfcode5423' /></p>
<div class='sfcode' id='sfcode5423'>
<p>$.jgrid.extend({</p>
<p>setCaption:function(newCaption){</p>
<p>var $t = this[0];</p>
<p>$(&#39;#&#39; + $t.p.id + &#39;_caption&#39;).html(newCaption);</p>
<p>},</p>
</div>
<p>and can be used like this</p>
<p><input type='button' class='sfcodeselect' name='sfselectit6535' value='Select Code' data-codeid='sfcode6535' /></p>
<div class='sfcode' id='sfcode6535'>$(&#39;#MyjqGrid&#39;).jqGrid(&#39;setCaption&#39;, &#39;My new super awesome caption!&#39;);</div>
<p>a simple but functional method,</p>
<p>regards!<img class="spSmiley" style="margin:0" title="Laugh" src="/blog/wp-content/forum-smileys/sf-laugh.gif" alt="Laugh" /></p>
]]></description>
        	        	<pubDate>Thu, 27 Oct 2011 18:04:55 +0300</pubDate>
        </item>
</channel>
</rss>