We hope you enjoy your visit.

You're currently viewing our forum as a guest. This means you are limited to certain areas of the board and there are some features you can't use. If you join our community, you'll be able to access member-only sections, and use many member-only features such as customizing your profile, sending personal messages, and voting in polls. Registration is simple, fast, and completely free.


Join our community!


If you're already a member please log in to your account to access all of our features:

Username:   Password:
Add Reply
[CODE] Resolution Warning; By General Anthraxus
Topic Started: Jan 25 2010, 08:36 AM (72 Views)
Reid
Member Avatar
È una trappola!

This topic has been moved from our official support board.

Originally posted by: General Anthraxus
[CODE
 
Resolution Warning]This should work if placed somewhere in the Header and Body Wrapper, I think above <Board> would be best.

Code:
 
<SCRIPT LANGUAGE="JavaScript1.2">
<!-- Begin
var bestwidth = INSERT WIDTH HERE;
var bestheight = INSERT HEIGHT HERE;
if (screen.width != bestwidth || screen.height != bestheight) {
msg = "This site looks best when viewed when your screen "
+ "is set to a " + bestwidth + "x" + bestheight + " resolution, "
+ "but your screen resolution is " + screen.width + "x"
+ screen.height + ". For best results, "
+ "please change your resolution, if possible. Thank you very much.";
document.write(msg);
}
// End -->
</script>

Simply Change the INSERT WIDTH HERE and INSERT HEIGHT HERE to the best resolution for viewing the site, for example, 800x600, 1024x760 etc.

If the user does not have that resolution or better set, a warning will appear.

To change the warning, find this
Quote:
 
msg = "This site looks best when viewed when your screen "
+ "is set to a " + bestwidth + "x" + bestheight + " resolution, "
+ "but your screen resolution is " + screen.width + "x"
+ screen.height + ". For best results, "
+ "please change your resolution, if possible. Thank you very much.";
document.write(msg);

And change the parts in speech marks, though you should always leave a space between the last character and the Speech Marks.
Offline Profile Quote Post Goto Top
 
1 user reading this topic (1 Guest and 0 Anonymous)
« Previous Topic · Codes & Modifications · Next Topic »
Add Reply