ronaldo cr ronaldo cr - 5 months ago 32
PHP Question

place html inside php code the right way and that works

i am trying to make html works and the right way to place it so it works placing html inside php code

<?php echo <td class=\"network\">".$show."</td>;?>


This does not give the impression that you've really tried much, or researched the issue.

<?php echo "<td class=\"network\">".$show."</td>";?>

^^ Should work to output HTML tags. (Though invalid as td should exist inside tables.)

Also note you can use different quotes to reduce the need for escaping. E.g.

<?php echo '<td class="network">'.$show.'</td>';?>