Adding a class via jQuery
<p>I have some code dynamically created by Sigma, which looks like this: </p>

<pre><code>&lt;div id="myGrid1_headDiv" class="gt-head-div"&gt;
&lt;div class="gt-head-wrap"&gt;
&lt;table id="myGrid1_headTable" class="gt-head-table"&gt;
&lt;tbody&gt;
&lt;tr class="gt-hd-row"&gt;
&lt;td class="gt-col-mygrid1-uid"&gt;
&lt;div class="gt-inner gt-inner-left" unselectable="on" title="#"&gt;
&lt;span&gt;#&lt;/span&gt;
&lt;div class="gt-hd-tool"&gt;&lt;span class="gt-hd-icon"&gt;&lt;/span&gt;
&lt;span class="gt-hd-button"&gt;&lt;/span&gt;
&lt;span class="gt-hd-split" style="cursor: col-resize; "&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;/td&gt;
&lt;td class="gt-col-mygrid1-p_deldate"&gt;
&lt;div class="gt-inner gt-inner-left" unselectable="on" title="Planned Delivery Date"&gt;
&lt;span&gt;Planned Delivery Date&lt;/span&gt;
&lt;div class="gt-hd-tool"&gt;&lt;span class="gt-hd-icon"&gt;&lt;/span&gt;
&lt;span class="gt-hd-button"&gt;&lt;/span&gt;
&lt;span class="gt-hd-split" style="cursor: col-resize; "&gt;&lt;/span&gt;&lt;/div&gt;&lt;/div&gt;&lt;/td&gt;
</code></pre>

<p>I am trying to target the un-classed spans( # and Planned Delivery Date), in order to style them, with:</p>

<pre><code>  $("div.gt-inner:first-child span")
    {
          $(this).addClass("celltitle");
        };
</code></pre>

<p>but it has no effect. As you can see, there other spans around it that I don't want to touch. What am I doing wrong?</p>

<p>=====
Final Answer for others using Sigma Grid:</p>

<p>Thanks to @minitech for the pointers, the answer is to add to Sigma Grid's gridOption with:</p>

<pre><code>onComplete:function(grid){ 
 $('div.gt-inner &gt; span').addClass('celltitle'); //add cell title after grid load
}
</code></pre>
