<?xml version="1.0" encoding="utf-8" ?><rss version="2.0" xml:base="https://www.webmaster-forums.net/crss/node/1012792" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title></title>
    <link>https://www.webmaster-forums.net/crss/node/1012792</link>
    <description></description>
    <language>en</language>
          <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/cookie-chaos#comment-1074087</link>
    <description> &lt;p&gt;Hi Ian,&lt;/p&gt;
&lt;p&gt;  Cookies are nice, aren&#039;t they? &lt;img src=&quot;https://www.webmaster-forums.net/misc/smileys/smile.png&quot; title=&quot;Smiling&quot; alt=&quot;Smiling&quot; class=&quot;smiley-content&quot; /&gt;&lt;/p&gt;
&lt;p&gt;  Any rate: while Max&#039;s solution will work, it won&#039;t help cutting down the code, especially if you decide to add  more cookies.  An alternative would be to put all of your information into a pseudo array and save it as the cookie.  Then when you retrieve the cookie, you simply split the array and retrieve your individual values.  &lt;/p&gt;
&lt;p&gt;var cookieData = &quot;&quot;;&lt;br /&gt;
cookieData = prompt(blahblah) ;&lt;br /&gt;
cookieData = &quot;|&quot; + lastVisitCode;&lt;/p&gt;
&lt;p&gt;var the_cookie = cookieData + &quot;;expires=&quot; +expireDate.toGMTString()&lt;/p&gt;
&lt;p&gt;when you retrieve it, you simply split the string into an array which you then assign appropriately:&lt;/p&gt;
&lt;p&gt;var tmpArray = cookieData.split(&quot;|&quot;);&lt;br /&gt;
var the_name = tmpArray[0];&lt;br /&gt;
var lastVisit = tmpArray[1];&lt;br /&gt;
...etc...&lt;/p&gt;
&lt;p&gt;Hope this helps&lt;br /&gt;
Vinny&lt;/p&gt;
 </description>
     <pubDate>Wed, 15 Nov 2000 01:58:30 +0000</pubDate>
 <dc:creator>Vincent Puglia</dc:creator>
 <guid isPermaLink="false">comment 1074087 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/cookie-chaos#comment-1074025</link>
    <description> &lt;p&gt;I&#039;m guessing that your creating a counter cookie as well (cause that&#039;s the value your reading), you didn&#039;t include it in the code, that&#039;s why I ask.&lt;/p&gt;
&lt;p&gt;Anyway, you&#039;ll eventually be using multiple cookies.  I dug this out of a book..&lt;br /&gt;
&lt;div class=&quot;codeblock&quot;&gt;&lt;code&gt;//pass the name of the cookie that you want to retrieve the value for&lt;br /&gt;&lt;br /&gt;function cookieVal(cookieName) {&lt;br /&gt;&amp;nbsp; thisCookie = document.cookie.split(&amp;quot;; &amp;quot;)&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; for (i=0; i&amp;lt;thisCookie.length; i++) {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (cookieName == thisCookie[i].split(&amp;quot;=&amp;quot;)[0]) {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return thisCookie[i].split(&amp;quot;=&amp;quot;)[1]&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;&amp;nbsp; return 0&lt;br /&gt;}&lt;/code&gt;&lt;/div&gt;&#039;&lt;/p&gt;
&lt;p&gt;This will loop through all your cookies looking for the cookieName that you passed it.  When it finds the cookie, it will return the value.&lt;/p&gt;
&lt;p&gt;Good Luck,&lt;/p&gt;
 </description>
     <pubDate>Tue, 14 Nov 2000 06:32:06 +0000</pubDate>
 <dc:creator>Mark Hensler</dc:creator>
 <guid isPermaLink="false">comment 1074025 at https://www.webmaster-forums.net</guid>
  </item>
  </channel>
</rss>
