title: if (true || true || false) statement is true in javascript?
body: <p>I have this bit of code to protect my page from being iframed. </p>
  
  <pre><code>window.onload = function(){
   try
    {
     if (window.parent &amp;&amp; window.parent.location.hostname !== "app.herokuapp.com"){
        throw new Error();
     }
     catch (e){
     //do something
     }
    }
  </code></pre>
  
  <p>It works perfectly fine until I try to add more values to compare the hostname with. I want to add my custom domain name. I tried this: </p>
  
  <pre><code>window.onload = function(){
   try
    {
     if (window.parent &amp;&amp; (window.parent.location.hostname !=="app.herokuapp.com" 
     || window.parent.location.hostname !== "www.app.com"
     || window.parent.location.hostname !== "localhost")){
        throw new Error();
     }
     catch (e){
     //do something
     }
    }
  </code></pre>
  
  <p>This always returns true and therefore throws an error.  How can I make this work? Unless the hostname matches these strings, I want to throw an error and it throws an error no matter what. I am new at this and would love some help! Thanks. </p>
  
  <p>Ps. I added "localhost" because I want to be able to test it locally before pushing to heroku. </p>