Jump to content

Remember Me


The Little Guy

Recommended Posts

<?php
$cookytme = "+604800";
$mmsalty = sha1($username);
setcookie("remembered", $mmsalty, time()+$cookytme);
?>

 

 

+3600 is an hour

+86400 is 24 hours

+604800 is 7 days

 

concept to make a time frame is

 

60 seconds x 60 minutes = +3600

3600 seconds x 24 hours = +86400

86400 seconds x 7 days = +604800

Link to comment
https://forums.phpfreaks.com/topic/120901-remember-me/#findComment-623221
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.