I am setting cookies using jquery+jquery cookie.
jQuery.cookie('status', 'active', {expires: 1, path: '/'});
Now how can I set this cookie using AJAX? regarless of jquery cookie, how would you set a cookie using ajax in jquery, anyone has any idea.
Links to original question (PHP & JQuery passing variables)
update
So I am making the AJAX request like so in my jquery code
$.ajax({
url: "script.php",
type: "GET",
data: { status: active}
});
And in my php I am processing it like;
if($_GET['status']!='')
{
setcookie("status", $_GET['status'], time()+3600);
}
but nothing is happening, no cookie is being set. can anyone see the problem,