Perl Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming LanguagesPerl Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
SlickEdit: Code in over 40 languages across 7 platforms. SlickEdit’s unmatched power, speed, and flexibility allows even the most accomplished developers to write better code faster. Download a free trial today!
  #1  
Old July 5th, 2000, 03:27 AM
chinnavi
Guest
Dev Shed Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:

i need a help in Cookies ..

I am using perl with CGI.pm

i want to set a cookie in the client side using CGI.pm ..
It is well and Fine working.
The problem is i couldnt able to set different valuefor the same cookie after some
pages displayed ...
i used this code ...

$CookieID = "$id+$password";

$cookies = $query->cookie(-name=>'b',
-value=>$CookieID
);

print $query->header(-cookie=>$cookies);

Anyone please tell me what is the problem..


vijay

Reply With Quote
  #2  
Old July 5th, 2000, 05:43 AM
Shiju Rajan's Avatar
Shiju Rajan Shiju Rajan is offline
.Net Developer
Dev Shed Novice (500 - 999 posts)
 
Join Date: Feb 2000
Location: London
Posts: 987 Shiju Rajan User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 3 h 26 m 22 sec
Reputation Power: 9
Send a message via MSN to Shiju Rajan Send a message via Yahoo to Shiju Rajan

$CookieID = "$id+$password";
$cookies = $query->cookie(-name=>'b',
-value=>$CookieID
);
print $query->header(-cookie=>$cookies);

-------------------
-------------------

Just try like following..

$CookieID =$id."+".$password;
# i don't what you are doing with this '+'

#pass one more argument 'expires'.(ie, set an expiry time for your cookie)

$cookies = $query->cookie(-name=>'b',
-value=>'$CookieID',-expires=>'+1h');

print $query->header(-cookie=>$cookies);

---------------
---------------


------------------
SR -
webshiju.com

"The fear of the LORD is the beginning of knowledge..."

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesPerl Programming > Cookie Problem!


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway