Help with a unexpected T_ELSE
<p>Now I have fixed the problem the T_ELSE parse error is not displaying anymore, But then how can I direct the code to display the if or the else?</p>

<p>Well users are going to come from either page1.php or page2.php  </p>

<pre><code>url coming from page1.php
cart.php?ids=1

url coming from page2.php
cart.php?idc=1
</code></pre>

<p>for instance if the url is coming from page1.php then cart is going to receive it like</p>

<p>$ids= isset($_GET['ids'])?(int) $_GET['ids']:null;</p>

<p>$idc= isset($_GET['idc'])?(int) $_GET['idc']:null;</p>

<pre><code>if ($ids) { 
display something
} 
elseif($idc) {
display something different
}
else 
{ 

display nothing has passed 
}
</code></pre>

<p>Those are the conditions I have right but it is not working properly since it will display the else message "display nothing has passed". Again it will display the else statement even if I come from page1.php or page2.php. I guess the conditions are not well set up or it is passing empty. How can I set up the conditions so it can display either $ids statement or the elseif $idc.</p>
