Bad Request follows cookies creation

S

samuelberthelot

Hi,
When the user clicks on an image, I creates cookies like that :

createCookie("CutFlags", getEl('ctl00_cpHidden_hidCutFlags').value,
0);
createCookie("OrgFlags", getEl('ctl00_cpHidden_hidOrgFlags').value,
0);
createCookie("OrgQuotes", getEl('ctl00_cpHidden_hidOrgQuotes').value,
0);
createCookie("CookieComments",
getEl('ctl00_cpBody_txtComments').value, 0);

function createCookie(name,value,days) {
if (days) {
var date = new Date();
date.setTime(date.getTime()+(days*24*60*60*1000));
var expires = "; expires="+date.toGMTString();
}
else var expires = "";
document.cookie = name+"="+value+expires+"; path=/";
}


The problem is that as soon as the next postback fires (I'm using
asp.net), it triggers a Bad Request in Firefox. Only way to get around
it, is to close the browser and reopen it. This doesn't occur in IE.
What do I do wrong ??

Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,768
Messages
2,569,574
Members
45,051
Latest member
CarleyMcCr

Latest Threads

Top