title: Get a 403 error on cookie save with javascript
body: <p>When I save a cookie with an encoded object inside, my browsers (both Chrome and Firefox) throw a 403 error on the page refresh. Things go back normal when I delete the cookie.</p>
  
  <p>My code : </p>
  
  <pre><code>var myObject = {test:true, test2:false};
  var exdays = 1;
  var cname = "save";
  var cvalue = encodeURIComponent(JSON.stringify(myObject));
  var d = new Date();
  d.setTime(d.getTime() + (exdays * 24 * 60 * 60 * 1000));
  var expires = "expires="+d.toUTCString();
  document.cookie = cname + "=" + cvalue + ";" + expires + ";path=/";
  </code></pre>
  
  <p>Where am I wrong ?</p>
  
  <p>Thanks</p>