if statement - PHP if else not working -


why if not working ? idea anyone.. know there minor wasted more half hour already.

                <?php if(1){ ?>               <?php                     echo "                       <ul class=\"nav navbar-nav navbar-right\">                         <li><a href=\"#\" data-toggle=\"modal\" data-target=\"#loginmodal\"><span class=\"glyphicon glyphicon-pencil\"></span> post</a></li>                       </ul>                       " ;               }?>              <?php else{ ?>                 <?php                   echo "                       <ul class=\"nav navbar-nav navbar-right\">                         <li><a href=\"#\" data-toggle=\"modal\" data-target=\"#loginmodal\"><span class=\"glyphicon glyphicon-pencil\"></span> post</a></li>                       </ul>                        ";                              }?> 

how this?

<?php     if(1){          echo "             <ul class=\"nav navbar-nav navbar-right\">                   <li><a href=\"#\" data-toggle=\"modal\" data-target=\"#loginmodal\"><span class=\"glyphicon glyphicon-pencil\"></span> post</a></li>             </ul>               " ;     }    else{        echo "            <ul class=\"nav navbar-nav navbar-right\">                  <li><a href=\"#\" data-toggle=\"modal\" data-target=\"#loginmodal\"><span class=\"glyphicon glyphicon-pencil\"></span> post</a></li>            </ul>               ";                     } ?> 

Comments

Popular posts from this blog

python - How to insert QWidgets in the middle of a Layout? -

python - serve multiple gunicorn django instances under nginx ubuntu -

module - Prestashop displayPaymentReturn hook url -