title: Detect the display resolution
body: <p>I need the help from people detecting the display resolution of a device using PHP.</p>
  
  <p>My code is in trouble when switching interface I have the following code:</p>
  
  <pre><code> $_page="home";
   if(get('page'))
      $_page=strtolower(get('page'));
   // Check if larger than 800px screen will show this code.
   $_pagePath='Includes/desktop/'.$_page.'_left.php';
   // Check if the screen is smaller than 800px will display this code.
   $_pagePath='Includes/mobile/'.$_page.'_left.php';  
   if(file_exists($_pagePath))
              include $_pagePath;
   else
      echo 'File '.$_pagePath.' not found';
  </code></pre>
  
  <p>Please help me finish this code.</p>