Use cookies to log on to the website. After debugging, use setcookie (username, username, time () + 1000,/php100/) to store user login information, then use setcookie (username, time ()-3600); to exit. there is no problem in testing in IE. As a website
Use cookies to log on to the website. After debugging, use
Setcookie ("username", "username", time () + 1000, "/php100 /");
To store user login information, and then use
Setcookie ("username", "", time ()-3600 );
Exit. there is no problem in testing in IE. As a website, you must be compatible with as many browsers as possible. As a result, it was normal to log on to Firefox and encountered problems when it was launched. The user is always logged on. So I checked the differences between cookie Records in IE and Firefox. after testing, I suddenly realized.
If the fourth parameter (valid path parameter) of setcookie () is not specified, the current directory is used as the valid path by default, and the path I tested is: http: // 127.0.0.1/php/rss2fla/data/log. php. Therefore, the cookie paths set during login and exit are different.
IE is more user-friendly than Firefox. haha, when a path is specified, it will overwrite the Cookie variable of the same name under the current IP address, while FireFox is more strict, resulting in a new variable ......
I feel that monopoly is not a disadvantage in some aspects. if I use IE as a browser, I don't have to worry about it ...... Haha ......