Baabu Posted July 1, 2007 Share Posted July 1, 2007 hi every one i m new to php programing i m stuck to sessions and cookies i have read some books but they aren't much statisfing can i one give me some practical examples for session handling and uses of cookies Best Regards Baabu Quote Link to comment https://forums.phpfreaks.com/topic/57925-sessions-and-cookies/ Share on other sites More sharing options...
sKunKbad Posted July 1, 2007 Share Posted July 1, 2007 I use a session with a cookie to track a shopping cart on my site. The session holds cart item info so that a customer can add and delete items and the shopping cart stays right even if they use the back button on their browser Quote Link to comment https://forums.phpfreaks.com/topic/57925-sessions-and-cookies/#findComment-287063 Share on other sites More sharing options...
Baabu Posted July 1, 2007 Author Share Posted July 1, 2007 Well i want tired to do some work with cookies as it is fine but i cant find any sort of cookie file in my temp directory just like for example <? setcookie('cookiename','value',time()+(60*60*24)); ?> the above code will make a cookie with the name cookiename value = value and expiry time 24 hours <? echo "The value of Cookie is".$_COOKIE['value']; ?> this will display the value on screen so how to do this step with sessions?? Quote Link to comment https://forums.phpfreaks.com/topic/57925-sessions-and-cookies/#findComment-287180 Share on other sites More sharing options...
trq Posted July 1, 2007 Share Posted July 1, 2007 There are MANY examples of using sessions all over the net. Do you really want us to write you a special tutorial? May I suggest you start here? Quote Link to comment https://forums.phpfreaks.com/topic/57925-sessions-and-cookies/#findComment-287184 Share on other sites More sharing options...
Baabu Posted July 1, 2007 Author Share Posted July 1, 2007 no no i dnt want you to write a tutorial for me i tried to find something with some examples but i cudn't anywayz thx for ur help i hope so this will help me out.. Quote Link to comment https://forums.phpfreaks.com/topic/57925-sessions-and-cookies/#findComment-287188 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.