<?xml version="1.0" encoding="utf-8" ?><rss version="2.0" xml:base="https://www.webmaster-forums.net/crss/node/1023234" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title></title>
    <link>https://www.webmaster-forums.net/crss/node/1023234</link>
    <description></description>
    <language>en</language>
          <item>
    <title></title>
    <link>https://www.webmaster-forums.net/serverside-scripting/i-need-cookie-clarification#comment-1143095</link>
    <description> &lt;p&gt;Well, just to learn I decided to do it using both cookies and sessions and see which one I liked better.  As for sessions, I&#039;ve encountered a problem and If any of you could help that would be great.  &lt;/p&gt;
&lt;p&gt;Sessions last on the server 1440 seconds (By default). On the client, the session cookie can last as long as you want it to last by using the&lt;br /&gt;
session_set_cookie_params() function. The problem is, i&#039;m trying to change how long the session lasts on the server.  Is this possible on a shared server.  I didn&#039;t think it would be since everyone on the server shares the same php.ini file.  But then I came across on set_ini function and if it has any bearing for this particular script i&#039;m trying to make.  I noticed every time i set a certain value, it just goes back to the default after the script is terminated....so that doesn&#039;t help me at all.  Does it normally stick but since i&#039;m on a shared server it just goes back to defaults or what.  What is the purpose of it.&lt;/p&gt;
 </description>
     <pubDate>Sat, 20 Dec 2003 23:18:04 +0000</pubDate>
 <dc:creator>section31</dc:creator>
 <guid isPermaLink="false">comment 1143095 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/serverside-scripting/i-need-cookie-clarification#comment-1142904</link>
    <description> &lt;p&gt;sounds good.&lt;/p&gt;
 </description>
     <pubDate>Wed, 17 Dec 2003 09:04:44 +0000</pubDate>
 <dc:creator>section31</dc:creator>
 <guid isPermaLink="false">comment 1142904 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/serverside-scripting/i-need-cookie-clarification#comment-1142903</link>
    <description> &lt;p&gt;what about encrypt the password twice ?&lt;br /&gt;
$pw = &#039;your_special_password&#039;;&lt;/p&gt;
&lt;p&gt;$password = md5(md5($pw, $realpassword));&lt;/p&gt;
&lt;p&gt;or something like that, as md5 can&#039;t be unencrypted, but can be worked out with program, esp if the users use dictionary words or numbers, adding your own password in there as well just makes that much harder.&lt;br /&gt;
then add it to a session inserted into a cookie&lt;/p&gt;
&lt;p&gt;[edit] might want to run it by Mark first, he&#039;s the PHP guru [/edit]&lt;/p&gt;
 </description>
     <pubDate>Wed, 17 Dec 2003 09:03:18 +0000</pubDate>
 <dc:creator>Busy</dc:creator>
 <guid isPermaLink="false">comment 1142903 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/serverside-scripting/i-need-cookie-clarification#comment-1142897</link>
    <description> &lt;p&gt;Yes.&lt;/p&gt;
&lt;p&gt;Is this for auto-login functionality?  I would advice some kind of encryption.  You don&#039;t want plain text username/passwords in a cookie.  Or perhaps use something other than a password in cookies... some kind of cookie key.&lt;/p&gt;
 </description>
     <pubDate>Wed, 17 Dec 2003 07:35:52 +0000</pubDate>
 <dc:creator>Mark Hensler</dc:creator>
 <guid isPermaLink="false">comment 1142897 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/serverside-scripting/i-need-cookie-clarification#comment-1142895</link>
    <description> &lt;p&gt;I even have a few books that do that.  Strange...&lt;/p&gt;
&lt;p&gt;So I should just make a function or something that checks the values of the cookies for each time they load the page?&lt;/p&gt;
 </description>
     <pubDate>Wed, 17 Dec 2003 07:27:08 +0000</pubDate>
 <dc:creator>section31</dc:creator>
 <guid isPermaLink="false">comment 1142895 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/serverside-scripting/i-need-cookie-clarification#comment-1142894</link>
    <description> &lt;p&gt;Uh.. I would certainly stay away from any script that merely checks if a cookie var is set, and not the value of the cookie.&lt;/p&gt;
&lt;p&gt;Personally, the only value I set in cookies is the session id (as you mentioned).  Everything else gets stored in a database in a session table (using the cookie-fied session id as a key).&lt;/p&gt;
&lt;p&gt;Can a cookie be faked.  Sure.  There are even ways to steal cookies, but I will not be getting into that for obvious reasons.&lt;/p&gt;
 </description>
     <pubDate>Wed, 17 Dec 2003 07:23:38 +0000</pubDate>
 <dc:creator>Mark Hensler</dc:creator>
 <guid isPermaLink="false">comment 1142894 at https://www.webmaster-forums.net</guid>
  </item>
  </channel>
</rss>
