General Programming Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsProgrammingGeneral Programming Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old May 22nd, 2002, 08:17 PM
gvimercati gvimercati is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Posts: 4 gvimercati User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Cookies!!! yum yum

Hi All,
A Quick Cookie question...

Im setting a login cookie to last 30 min from when the user last loads a page. in other words i re-set the cookie-time every time a new page is loaded.... now ive noticed that the cookie creates more than one copy of itself whenever a page is loaded from a different directory.

So in the end i get an instance of the cookie for every directory in my code... the problem lies when a user hasn't accessed the original directory for more than 30 min but has been working in a different directory, the get a timed out error.

can Cookies be set to be specific to the entire site instead of being directory specific?

gianni

Reply With Quote
  #2  
Old May 22nd, 2002, 08:42 PM
Ben Rowe
Guest
Dev Articles Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
ahhh, crap, its been ages since ive used cookies, hmm, ive got a feeling that it is possible to do what your saying, i just cant remember how, i think when you create the cookie, their is some var that you set that keeps it for the dir and the dirs above that.

still ive been no help, maybe someone else has an idea of how to do this??
soz

Reply With Quote
  #3  
Old May 22nd, 2002, 09:26 PM
epyon epyon is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: May 2002
Location: Chicago
Posts: 22 epyon User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
set the cookie directory to /
setcookie('blah', 'moo', $time, '/', '.domain.com');

Reply With Quote
  #4  
Old May 22nd, 2002, 10:06 PM
Ben Rowe
Guest
Dev Articles Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
ahh thats it!, hehe, its been soo long since ive used cookies, mainly due to the fact that most people (who have trouble starting the computer) have cookies turned off!, so i rely on databases, ips and the like, to replace cookies.

Reply With Quote
  #5  
Old May 23rd, 2002, 01:41 AM
James Yang James Yang is offline
Contributing User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Location: Atlanta, Georgia
Posts: 284 James Yang User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 2 m 45 sec
Reputation Power: 7
Send a message via ICQ to James Yang
IE Even blocks them for ya.. so cookie does great job in doing nothing.. it's good especially for vote program to chk if user has voted or not.. cuz ie blocks them and it just won't work..damn cookies.

oh one more thing about cookies using ie u can look at other ppls cookies.. there is tough unbreakable security for ya.
__________________
Regards,

James Yang
.NET Developer / Network Engineer
MCSE, MCDBA, MCSA, CCNA

http://www.yellowpin.com/
http://www.opentechsupport.com/

Reply With Quote
  #6  
Old May 23rd, 2002, 04:46 PM
epyon epyon is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: May 2002
Location: Chicago
Posts: 22 epyon User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
what? i'm using ie and it does not block cookies.

Reply With Quote
  #7  
Old May 23rd, 2002, 05:35 PM
Ben Rowe
Guest
Dev Articles Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
the default setting for IE blocks most cookies, if you set your cookies acording the IE rules or you change your settings, you will then exept cookies, also if you upgrade IE over the top of your current installation you settings will be kept, i allow all cookies, since they help store data, i rather not have to remember.

check your IE cookie settings, the security is probally turned off!

Reply With Quote
  #8  
Old May 24th, 2002, 12:29 AM
James Yang James Yang is offline
Contributing User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Location: Atlanta, Georgia
Posts: 284 James Yang User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 2 m 45 sec
Reputation Power: 7
Send a message via ICQ to James Yang
sorry i was just paying out cookies ...(how sad do i sound here)

to clarify..since the release of IE6, MS decided taht cookie is not the way to go.. so they have restricted sites using cookies tightly..

many cookies are blocked cuz of this...

Reply With Quote
  #9  
Old May 24th, 2002, 03:54 PM
epyon epyon is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: May 2002
Location: Chicago
Posts: 22 epyon User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
stupid microsoft.
so what is their 'great' new method?

Reply With Quote
  #10  
Old December 6th, 2002, 05:50 PM
Attila Attila is offline
Contributing User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Aug 2002
Posts: 67 Attila User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 7
Quote:
Originally posted by Ben Rowe
ahh thats it!, hehe, its been soo long since ive used cookies, mainly due to the fact that most people (who have trouble starting the computer) have cookies turned off!, so i rely on databases, ips and the like, to replace cookies.


Ben if you do not use cookies to remember who the person is when they come back...I beleive you are doing something like this?

1. Get their IP address..
2. Store their IP address in a database.
3. When person comes back check to see if their IP address is in the database if it is then they are that person?

4. If that is the case how do you deal with dynamic IP addresses?

Sorry I am trying to get a cookie or something along that line to remember who the person is when they come back. Can someone give me not a little nudge!!! (LOL) but a BIG PUSH with some coding of what they are doing?
__________________
Thanks,
Attila
http://www.glorynaspiration.com
http://www.abitofthings.com

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingGeneral Programming Help > Cookies!!! yum yum


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 5 hosted by Hostway
Stay green...Green IT