title: php notices Undefined error with php 5.4+
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/4261133/php-notice-undefined-variable-and-notice-undefined-index">PHP: &ldquo;Notice: Undefined variable&rdquo;  and &ldquo;Notice: Undefined index&rdquo;</a>  </p>
  </blockquote>
  
  
  
  <p>I upgrade/install <code>PHP 5.4.4</code> (xampp 1.8.0) in localhost. now i see many <code>notice error</code> in my page. what's problem? how to fix this?</p>
  
  <p>Secion Of Error : </p>
  
  <pre><code>Notice: Undefined index: language in C:\xampp\htdocs\tube\include\config.php on line 93
  
  Notice: Undefined variable: max_avatar_width in C:\xampp\htdocs\tube\include\lang\english.php on line 495
  
  Notice: Undefined variable: max_avatar_height in C:\xampp\htdocs\tube\include\lang\english.php on line 496
  
  Notice: Undefined index: USERID in C:\xampp\htdocs\tube\index.php on line 26
  </code></pre>
  
  <p>Config PHP page :</p>
  
  <pre><code>if ($_REQUEST['language'] != '') // &lt;---- Line 93 
  {
      if ($_REQUEST['language'] == 'english')
      {
  
          $_SESSION['language'] = 'english';
      }
      elseif ($_REQUEST['language'] == 'spanish')
      {
  
          $_SESSION['language'] = 'spanish';
      }
  }
  
  if ($_SESSION['language'] == "")
  {
  
      $_SESSION['language'] = "english";
  }
  
  if ($_SESSION['language'] == "english")
  {
  include("lang/english.php");
  }
  elseif ($_SESSION['language'] == "spanish")
  {
  include("lang/spanish.php");
  }
  else
  {
  include("lang/english.php");
  }
  </code></pre>
  
  <p>English Lang Page (line 495 and 496) : </p>
  
  <pre><code>$lang['491'] =  "The image width is too big. Max width is $max_avatar_width pixels."; 
  $lang['492'] =  "The image height is too big. Max height is $max_avatar_height pixels.";
  </code></pre>
  
  <p>Index PHP Page:</p>
  
  <pre><code>if($_SESSION['USERID'] == "") // &lt;-- Line 26
  {
      $showfamfilter = "AND mature='0'";
  }
  elseif($_SESSION['FAMILYFILTER'] == "0")
  {
      $showfamfilter = "";
  }
  else
  {
      $showfamfilter = "AND mature='0'";
  }
  </code></pre>