Re: [PHP] Remember username and password

2004-06-01 Thread John W. Holmes
From: "Phpu" <[EMAIL PROTECTED]>

> How can i make a registration form that will remember
> my username and password every time i login from the same computer?
> I think i should set a cookie but i don't know how.

http://us2.php.net/setcookie

Don't put the username and password in the cookie. You need to set a unique
identifier in the cookie that is related to the username and password on the
server side. md5() and uniqid() can come in handy for this.

---John Holmes...

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Remember username and password

2004-06-01 Thread "Miguel J. Jiménez"
Yes, you must use a cookie with function setcookie() before any header 
is sent...

Phpu wrote:
Hi,
How can i make a registration form that will remember my username and password every 
time i login from the same computer?
I think i should set a cookie but i don't know how.
Thanks

---
avast! Antivirus: Mensaje ENTRANTE limpio.
Base de datos de Virus (VPS): 0422-1, 27/05/2004
Fecha: 01/06/2004 13:01:38

 

--
Miguel J. Jiménez
ISOTROL, S.A. (Área de Internet)
Avda. Innovación nº1, 3ª - 41020 Sevilla (ESPAÑA)
mjjimenez AT isotrol DOT com   ---   http://www.isotrol.com
ICQ# 12670750
TLFNO. 955036800 ext. 111
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[PHP] Remember username and password

2004-06-01 Thread Phpu
Hi,

How can i make a registration form that will remember my username and password every 
time i login from the same computer?
I think i should set a cookie but i don't know how.

Thanks