Eythan Fellous Eythan Fellous - 1 year ago 58
PHP Question

PHP tag is not recognized in HTML

I'm trying to implement a PHP tag in HTML but, it doesn't work and I don't understand why.

It's not a Webserver problem , look the code error is on the code

PHP file:

<div class="row">
<div class="col-xs-12 results-count">
<?php if ($hebergement['count'] == 1){ ?>
hébergement correspond à votre recherche
<?php } else { ?>
<strong><?php echo $hebergements['count']; ?></strong> hébergements correspondent à votre recherche
<?php }?>
</div>
</div>

Answer Source

try this:

   <div class="row">
    <div class="col-xs-12 results-count">
        <?php if ($hebergement['count'] == 1)
            {
                echo "hébergement correspond à votre recherche";
            }else{
                    echo"<strong>.$hebergements['count'].</strong>hébergements correspondent à votre recherche";
            }
              ?>
    </div>
</div>

hope thi help you a little

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download