Constructing a javascript variable
<p>Here is my jQuery:</p>

<pre><code>jQuery( document ).ready( function ( $ ) {
    $('ul li:first-child').addClass( 'first_item' );
    var className = $('.first_item').attr('id');
    alert('Date is:'+ className +'.');
});
</code></pre>

<p>And then this another section of jQuery, that im trying to contrust a variable in:</p>

<pre><code>j(".refreshMe").everyTime(5000, function (i) {
    j.ajax({
        url: "test.php?latest=" + className + "",
        cache: false,
        success: function (html) {
            j(".refreshMe").html(html);
        }
</code></pre>

<p>Its this line:</p>

<pre><code>url: "test.php?latest="+className+"",
</code></pre>

<p>Im trying to take the className variable and feed it into this line.</p>

<p>Can anyone suggest what im doing wrong here?</p>
