title: PHP - else, 'escape' nesting and skip to elseif
body: <p>I wasn't too sure how to title this question - Here's a snippet of what I'm doing:</p>
  
  <pre><code>&lt;?php
    if ($result_rows &gt;= 1 &amp;&amp; $membership = 'active') {
       if ($when_next_allowed &gt; $today_date) {
           $output = 'You cannot renew your membership for another &lt;b&gt;' . $days_left . 'days&lt;/b&gt;.';
       }
       /*
       What if the membership is set to active, but it's been over a year since they
       activated it? We don't have any server-side functions for determining such
       at the time.
       */
       else {
           /* do database stuff to change the database entry to inactive */
           /* skip to elseif below */
       }
    }
    elseif (2 == 2) {
       /* create new database entry for user's membership */
    }
  ?&gt;
  </code></pre>
  
  <p><strong>If</strong> the first nested argument is <strong>false</strong>, it should move onto <strong>else</strong> which should continue from there and 'escape' the 'parent' if and move onto <strong>elseif</strong>. Other wise, <strong>if</strong> the first nested argument is <strong>true</strong>, then it should stay put.</p>
  
  <p>Is that even a possible occurrence? The only thing I could think of was to add multiple <code>continue;</code> commands. That, of course, threw an error.</p>
  
  <p>One other idea I had was setting a variable to equal <strong><code>continue;</code></strong> within the <strong>else</strong>, then set that right before the end of the parent if:</p>
  
  <pre><code>if (1 == 1) {
  ...
    else {
         $escape = 'continue;';
    }
  /* $escape here */
  }
  </code></pre>
  
  <p>But I've never heard of, nor do I know of any method of using variables in a 'raw' form like that. Of course I've done research on it, though I've yet to find out how. I'm not sure if that's common knowledge or anything - But I've never heard of, or considered such a thing until now.</p>
  
  <p>Solution? This is something I always thought about, though I never knew I'd have to use it.</p>