Thanks
Can someone maybe help me out?
Moderator: General Moderators
-
Tasmanian Devil
- Forum Newbie
- Posts: 2
- Joined: Fri Jul 25, 2003 10:36 am
Can someone maybe help me out?
I am looking for a php to be able to search the users computer to see if cookies and/or javascript enabled. If one or both are disabled, I want the user to go to one page, but if both enabled, to go to another page
Thanks
Thanks
You can use get_browser() to get the javascript information.
http://us2.php.net/function.get-browser
You can also check and see if people have cookie capable browsers, but the only way I know of to check if they are actually enabled is to use set_cookie() and then reload the page and check for a value. If there is no value then cookies aren't enabled. You can then use
header("Location: /path/to/file.php");
to refresh your browser, and or redirect to another page.
http://us2.php.net/function.get-browser
You can also check and see if people have cookie capable browsers, but the only way I know of to check if they are actually enabled is to use set_cookie() and then reload the page and check for a value. If there is no value then cookies aren't enabled. You can then use
header("Location: /path/to/file.php");
to refresh your browser, and or redirect to another page.