title: Simple Javascript/JQuery Cookie Question
body: <p>I've got an animation that I want to play only once and I figured that since the animation was in JQuery, the function to write the cookie file should be as well.</p>
  
  <p>So far I've got:</p>
  
  <pre><code>$(document).ready(function(){
  
  if (!$.cookie('cookieName'))
   {
      setTimeout(function() {    
      $('#intro').fadeOut(1000); 
   }, 5000);
  };
  
  $.cookie('cookieName', 'the_value');
  
  });
  </code></pre>
  
  <p>I guess I was thinking this was going to check to see if there was a cookie and if not then play the animation. When that was done it writes a cookie and so when I come back to the page it doesn't play. I'm calling the Klaus Hartl cookie plugin and for some reason this just isn't doing it for me.</p>
  
  <p>Much appreciated.</p>