Is it possible to take info about user's screen resolution, put it on a variable and do something as
if($screen==800x600){
do something}
else{
do other thing}
?
Screen resolution
yes, it is possible, but not with php. U should use client side scripting language- javascript:
in page resolution.php u will have global variables $w and $h with screen resulution
Browser Compatibility: NS 4+, IE 5+, Firefox
Taken and edited from http://www.pageresource.com/jscript/jscreen.htm
Code: Select all
<SCRIPT language="JavaScript">
<!-- this javascript code is right, but i dont say exactly same about syntax. Review it if it will not work
window.location='resolution.php?w='+screen.width+'&h='+screen.height;
//-->
</SCRIPT>
Browser Compatibility: NS 4+, IE 5+, Firefox
Taken and edited from http://www.pageresource.com/jscript/jscreen.htm

-
- Posts: 504
- Joined: Sat May 07, 2005 8:03 am
- Contact: