Javascript cookie variable problems
<p>I am trying to change the cookie on a page after a simple form is submitted.  Here is the code:</p>

<pre><code>&lt;script&gt;


function setnewCookie(){

var frack = $('.value').text();
var exp = new Date();                                   // make new date object
exp.setTime(exp.getTime() + (1000 * 60 * 60 * 24 * 30)); // set it 30 days ahead

setCookie("phoneC", frack, exp);     //save the cookie 
}


&lt;/script&gt;
</code></pre>

<p>The <em>var frack = $('.value').text();</em> seems to be where the issue is.  The <em>.value</em> is a class in a span tag with a simple phone number.  I want to pass that phone number into the cookie.   Can anyone tell me why this isnt working?</p>
