Jump to content

Include php code in MySQL text fields


roberthj

Recommended Posts

I can display text stored in a MySQL database VARCHAR field using, e.g., <?php echo $row_publicpages['h1text'];?>

 

I have managed to include HTML tags in the text field by enclosing it in '<html stuff>'. This works but the enclosing ' ' show on the page. If anyone has a way of hiding the ' ' I would like to know.

 

But I have run into a brick wall trying to include php code in the text field - such as <?php echo $row_charge['ocean_diver']; ?>

 

It just does not work!!!

 

And I would really like to be able to do this!!!

 

Any suggestions out there?

 

Please keep answers simple as I am VERY new to all this!!

 

Rob

Link to comment
https://forums.phpfreaks.com/topic/107185-include-php-code-in-mysql-text-fields/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.