Jump to content

[SOLVED] How not to display HTML?


Kemik

Recommended Posts

Hello,

 

I'm making a news system for my website. I've created an admin area where I can edit currently posted news. I have all my news listed in a table with the variables $newsid, $title, $content.

 

$content is saved in the database as html code. Is there anyway of displaying the html code without in executing. E.g. When I pull $content it displays:

 

<b>Today</b> I went to the shops.<br />They were closed.

 

Instead of:

 

Today I went to the shops.

They were closed.

 

Thanks.

Link to comment
https://forums.phpfreaks.com/topic/61387-solved-how-not-to-display-html/
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.