Forum Moderators: coopster

Message Too Old, No Replies

Cookie problem after editing my .htaccess

         

Gian04

1:45 pm on Aug 9, 2007 (gmt 0)

10+ Year Member



I have edited my htcaess that redirect index.php to root and add the www if someone didn't type it.

I dont have any problem setting the cookie before adding these lines to my htaccess file.

The form will be submitted to self [index.php], and after validating the inputs will set the cookie

setcookie("cookiename", $username, time()+86400, "/", ".example.com");

Then will display the same page [index.php] with a different sets of items

[edited by: Gian04 at 1:50 pm (utc) on Aug. 9, 2007]

Gian04

9:48 am on Aug 11, 2007 (gmt 0)

10+ Year Member



Anyone?

jatar_k

12:27 pm on Aug 11, 2007 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



does the cookie not get set?

I don't understand what exactly is happening

Gian04

12:40 pm on Aug 11, 2007 (gmt 0)

10+ Year Member



Yes cookies dont set

jatar_k

12:51 pm on Aug 11, 2007 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



try removing the . from the domain in the cookie