title: If Statement not working with And (&&) Operator
body: <p>I'm having a hard time writing up what seems should be a simple if statement! I need it to say if mod does not equal a, b, or c - then do this. Here is what I was trying but have been unsuccessful:</p>
  
  <pre><code>var mod = CURRENT_MODULE_ID;
  if (mod != "5827289" &amp;&amp; mod != "5195103" &amp;&amp; mod != "5181422") {
     doSomething();
  }
  </code></pre>
  
  <p>When I type this into my editor it says there is an error, specifically that "The entity name must immediately follow the '&amp;' in the entity reference."
  .. and is not working when I go to test.</p>
  
  <p>Any help is appreciated!!</p>
  
  <hr>
  
  <p>UPDATE:
  The url: esber.squarespace.com</p>
  
  <p>The full script:</p>
  
  <pre><code>&lt;script type="text/javascript" src="/storage/scripts/sessvars.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript"&gt;
  &lt;![CDATA[ 
  
  onload=function(){
   sessvars.browserConfirmation?'none':'';
   sessvars.ageConfirmation?'none':'';
  }; 
  
  var mod = Squarespace.Constants.CURRENT_MODULE_ID;
  if (mod != "5827289" &amp;&amp; mod != "5195103" &amp;&amp; mod != "5181422") {
     if(sessvars.ageConfirmation != "yes"){
        window.location = "/verify/";
     };
  };
  
  ]]&gt;
  &lt;/script&gt; 
  </code></pre>
  
  <p>I want every page in the site to automatically redirect on page load to the verify page, unless it is the verify page (/verify), the "You are not verified" page (/not-verified), or the login page (/login) -- unless the user already verified by setting the sessvars, then they can continue on to the homepage.</p>
  
  <p>To test this I go to esber.squarespace.com and click on one the menu items at the right (this menu would eventually be hidden when I'm done with the page) -- when i try to go to another page without veriying my age first i should be redirected back to the /verify page but that isnt happening.</p>
  
  <p>If i revise the script to:</p>
  
  <pre><code>&lt;script type="text/javascript" src="/storage/scripts/sessvars.js"&gt;&lt;/script&gt;
  &lt;script type="text/javascript"&gt;
  
  onload=function(){
   sessvars.browserConfirmation?'none':'';
   sessvars.ageConfirmation?'none':'';
  }; 
  
  var mod = Squarespace.Constants.CURRENT_MODULE_ID;
  if (mod != "5827289") {
     if(sessvars.ageConfirmation != "yes"){
        window.location = "/verify/";
     };
  };
  
  &lt;/script&gt; 
  </code></pre>
  
  <p>then it works fine(?)</p>