<?xml version="1.0" encoding="utf-8" ?><rss version="2.0" xml:base="https://www.webmaster-forums.net/crss/node/1011657" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title></title>
    <link>https://www.webmaster-forums.net/crss/node/1011657</link>
    <description></description>
    <language>en</language>
          <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/detecting-screen-resolution-then-redirecting#comment-1067498</link>
    <description> &lt;p&gt;Probably goes without saying, but be carefull on the conditionals....&lt;/p&gt;
&lt;p&gt;Have a fall back redirect so that if the user has say 1600x1280 that you have a match on your conditional statements.&lt;/p&gt;
&lt;p&gt;I recommend using a set such as:&lt;/p&gt;
&lt;p&gt;var userWidth = screen.width;&lt;br /&gt;
var userHeight = screen.height; &lt;/p&gt;
&lt;p&gt;if (userWidth &amp;lt;= 640){&lt;br /&gt;
  myWidth=640;&lt;br /&gt;
}else if (userWidth &amp;lt;=800){&lt;br /&gt;
  myWidth=800;&lt;br /&gt;
}else{&lt;br /&gt;
  myWidth=1024;&lt;br /&gt;
}&lt;br /&gt;
if (userHeight &amp;lt;= 480) {&lt;br /&gt;
  userHeight =480;&lt;br /&gt;
}else if (userHeight &amp;lt;=600){&lt;br /&gt;
  userHeight =600;&lt;br /&gt;
}else{&lt;br /&gt;
  userHeight =768;&lt;br /&gt;
}&lt;/p&gt;
&lt;p&gt;if(myWidth&amp;gt;=1024 &amp;amp;&amp;amp; myHeight&amp;gt;=768){&lt;br /&gt;
  location = &quot;page1024768.html&quot;;&lt;br /&gt;
} else if (myWidth &amp;gt;= 800 &amp;amp;&amp;amp; myHeight &amp;gt;= 600) {&lt;br /&gt;
  location = &quot;page800600.html&quot;;&lt;br /&gt;
} else {&lt;br /&gt;
  location = &quot;page640480.html&quot;;&lt;br /&gt;
}&lt;/p&gt;
&lt;p&gt;This is a verbose example, you can certainly combine the two sections, key is to make sure you cover odd sizes/combos.&lt;/p&gt;
&lt;p&gt;Tazman&lt;/p&gt;
&lt;p&gt;[Edited by tazman on 07-15-2000 at 03:34 PM]&lt;/p&gt;
 </description>
     <pubDate>Sat, 15 Jul 2000 19:14:51 +0000</pubDate>
 <dc:creator>tazman</dc:creator>
 <guid isPermaLink="false">comment 1067498 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/detecting-screen-resolution-then-redirecting#comment-1067468</link>
    <description> &lt;p&gt;Easy:&lt;/p&gt;
&lt;p&gt;if (userWidth == 640 &amp;amp;&amp;amp; userHeight == 480) {&lt;br /&gt;
window.setTimeout(&quot;location = &#039;page640480.html&#039;&quot;,1000 * 10);&lt;br /&gt;
}&lt;/p&gt;
 </description>
     <pubDate>Sat, 15 Jul 2000 16:11:37 +0000</pubDate>
 <dc:creator>Lloyd Hassell</dc:creator>
 <guid isPermaLink="false">comment 1067468 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title>Add a setTimeout function??</title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/detecting-screen-resolution-then-redirecting#comment-1067210</link>
    <description> &lt;blockquote class=&quot;bb-quote-body&quot;&gt;&lt;p&gt;Quote: &lt;em&gt;Originally posted by Lloyd Hassell &lt;/em&gt;&lt;br /&gt;
&lt;strong&gt;var userWidth = screen.width;&lt;br /&gt;
var userHeight = screen.height;&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;if (userWidth == 640 &amp;amp;&amp;amp; userHeight == 480) {&lt;br /&gt;
   location = &quot;page640480.html&quot;;&lt;br /&gt;
   }&lt;br /&gt;
else if (userWidth == 800 &amp;amp;&amp;amp; userHeight == 600) {&lt;br /&gt;
   location = &quot;page800600.html&quot;;&lt;br /&gt;
   } &lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;It worked like a charm - thanks!&lt;/p&gt;
&lt;p&gt;Is it possible to incorporate a setTimeout function?  I want the redirect to the appropiate page to be delayed by about 10 seconds.&lt;/p&gt;
 </description>
     <pubDate>Wed, 12 Jul 2000 13:01:28 +0000</pubDate>
 <dc:creator>mizzie</dc:creator>
 <guid isPermaLink="false">comment 1067210 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/detecting-screen-resolution-then-redirecting#comment-1066957</link>
    <description> &lt;p&gt;var userWidth = screen.width;&lt;br /&gt;
var userHeight = screen.height;&lt;/p&gt;
&lt;p&gt;if (userWidth == 640 &amp;amp;&amp;amp; userHeight == 480) {&lt;br /&gt;
   location = &quot;page640480.html&quot;;&lt;br /&gt;
   }&lt;br /&gt;
else if (userWidth == 800 &amp;amp;&amp;amp; userHeight == 600) {&lt;br /&gt;
   location = &quot;page800600.html&quot;;&lt;br /&gt;
   }&lt;/p&gt;
 </description>
     <pubDate>Fri, 07 Jul 2000 16:17:50 +0000</pubDate>
 <dc:creator>Lloyd Hassell</dc:creator>
 <guid isPermaLink="false">comment 1066957 at https://www.webmaster-forums.net</guid>
  </item>
  </channel>
</rss>
