Set Cookes in java script

Set Cookes

      <script type = "text/javascript">
            function WriteCookie()
               if( document.myform.customer.value == "" ){
                  alert("Enter some value!");
               cookievalue= escape(document.myform.customer.value) + ";";
               document.cookie="name=" + cookievalue;
               document.write ("Setting Cookies : " + "name=" + cookievalue );
      <form name="myform" action="">
         Enter name: <input type="text" name="customer"/>
         <input type="button" value="Set Cookie" onclick="WriteCookie();"/>


Popular posts from this blog

Set the variables to different values and different operators and then try...

auto redirected page in java script