title: PHP if not statements
body: <p>This may be the way my server is set up, but I'm banging my head against the wall. I'm trying to say that if <code>$action</code> has no value or has a value that is not "add" or "delete" then have an error, else keep running the script. However, I get an error no matter what <code>$action</code> is.</p>
  
  <pre><code> $action = $_GET['a'];
   if((!isset($action)) || ($action != "add" || $action != "delete")){
       //header("location:index.php");
       echo "error &lt;br&gt;";
   }
  </code></pre>
  
  <p><code>$action</code> is being set properly and if run something like <code>if($action =="add")</code> it works. This is on my local host, so it could be a settings issue.</p>