Reply
strip html
Old 05-07-2008, 01:14 AM strip html
Junior Talker

Posts: 3
is there a command to strip html from input
__________________
LifeTime hosting
aspark is offline
Reply With Quote
View Public Profile
 
When You Register, These Ads Go Away!
     
Old 05-07-2008, 01:30 AM Re: strip html
JeremyMiller's Avatar
Full-Time TeraTasker

Posts: 804
Name: Jeremy Miller
Location: Reno, NV
Look for http://www.php.net/strip_tags
__________________
Jeremy Miller - TeraTask Technologies, LLC
Content Farmer - Automated Posting for Content & Blog Sites
JeremyMiller is offline
Reply With Quote
View Public Profile Visit JeremyMiller's homepage!
 
Old 05-07-2008, 09:35 AM Re: strip html
dansgalaxy's Avatar
Eat, Sleep, Code

Latest Blog Post:
New College Enrollment.
Posts: 5,790
Name: Dan
Location: Swindon
Lol why do i always seem to get beaten to the easy Questions lol..

__________________
Personal UK Webhosting
Get 25% of ANY shared package for life ~ Promo: webmaster-talk
dansgalaxy is offline
Reply With Quote
View Public Profile Visit dansgalaxy's homepage!
 
Old 05-07-2008, 12:08 PM Re: strip html
Average Talker

Posts: 15
Name: Mark
who is the input being used, are you adding it to the database and then displaying it? you can use:

$str = "A 'quote' is <b>bold</b>";

// Outputs: A 'quote' is &lt;b&gt;bold&lt;/b&gt;
echo htmlentities($str);
// Outputs: A 'quote' is &lt;b&gt;bold&lt;/b&gt;
echo htmlentities($str, ENT_QUOTES);

then decode it afterwards for display:

html_entity_decode()
Datingsoftware is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to strip html
 

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML

 


Page generated in 0.12246 seconds with 13 queries