...

View Full Version : Insert HTML



moisesbr
08-29-2011, 03:53 PM
Hi

How can I insert HTML tags into a php code whithout using echo or print commands ?

Moises

bucket
08-29-2011, 03:56 PM
Just break the php code up...


?>

HTML STUFF HERE

<?php

Then start it again.

moisesbr
08-29-2011, 04:31 PM
Thanks

Because of pure HTML I will not use quotes as I used with echo.

So, which is the correct way to insert variables along the HTML code ?

'.$nome_curso.'

or

.$nome_curso.

?

The problem is that literally is shown $nome_curso and not the variable value.


<td><font color="#66ccff" face="Arial"><big><strong>
<font size="5">Pedido de curso</font></strong></big></font>
<p><font face="Arial"><big><strong>.$nome_curso.</strong></big></font><br>
<br>
&nbsp;</td>


Moises









Just break the php code up...


?>

HTML STUFF HERE

<?php

Then start it again.

bucket
08-29-2011, 04:38 PM
Something like


<BODY>
<b> <?php echo $nome_curso; ?> </b>
</BODY>

moisesbr
08-29-2011, 05:05 PM
Thank you

I was able to insert de variable without having to echo the whole line.

Moises




Something like


<BODY>
<b> <?php echo $nome_curso; ?> </b>
</BODY>



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum