title: Why can't I get the cookie's value with Jinput in Joomla 2.5+?
body: <p><strong>QUESTION</strong></p>
  
  <p>Why can't I get the cookie's value with Jinput in Joomla 2.5+? </p>
  
  <p><strong>DETAILS</strong></p>
  
  <p>I used to use </p>
  
  <pre><code>$cookievalue = JRequest::getVar( 'cookievalue', 'valueifnotexist', 'COOKIE' );
  </code></pre>
  
  <p>but it is deprecated in joomla 3.</p>
  
  <p>So I tried using Jinput</p>
  
  <pre><code>$jinput = JFactory::getApplication()-&gt;input;
  $cookievalue = $jinput-&gt;get( 'cookievalue', 'valueifnotexist', 'COOKIE' );
  </code></pre>
  
  <p><strong>NOTE:</strong> According to <a href="http://docs.joomla.org/Retrieving_request_data_using_JInput" rel="nofollow">http://docs.joomla.org/Retrieving_request_data_using_JInput</a> there is no 'COOKIE' filter. I've tried using 'STRING' as the filter, but the results are much the same. The value I'm expecting to get for the cookie is in the format <code>date( 'Y-m-d H:i:s', time() )</code></p>
  
  <p><strong>RESULTS</strong></p>
  
  <p>When I check to see if the value has been retrieved I always get 'valueifnotexist'
  I've used firebug to confirm that the cookie/value exists.</p>