plz help

delon

Banned
Messages
397
Reaction score
0
Points
0
when someone visits my website and if they have a screen resolution below 1024 x 768 and then are redirected to an another page. how can i do that.
 

woocorp

New Member
Messages
50
Reaction score
0
Points
0
good idea, but you could create a gateway page asking them what there resolution is, than whateva button they click will determin what site they goto, alternativly you could use a popup
 

Pi606

New Member
Messages
85
Reaction score
0
Points
0
Here's the code that should do it for ya automatically:
Code:
function Redirect() {
  if ((Screen.displayWidth < 1024) && (Screen.displayHeight < 780)) {
    window.location.href="PATH OF THE PAGE TO REDIRECT TO";
  }
}

And then you should add this to your <body> tag:
HTML:
<body onload="Redirect();">

For the user to click a button to select:
HTML:
<p>What's your screen resolution?</p>
<input type="button" value="Less than 1024x780" onclick="window.location.href='page1.html';" />
<input type="button" value="1024x768 or greater" onclick="window.location.href='page2.html';" />
 
Last edited:

leafypiggy

Manager of Pens and Office Supplies
Staff member
Messages
3,819
Reaction score
163
Points
63
lmao..i liked this one

Code:
 class Brick implements Throwable { ... }

and yeah. that should do it
 
Top