Jump to content


Photo

Help on PHP pettern matching pattern detecting HTML tags.


  • Please log in to reply
2 replies to this topic

#1 adisonz

adisonz
  • New Members
  • Pip
  • Newbie
  • 1 posts

Posted 30 July 2006 - 04:40 AM

My forms include <textarea> to allow members to key in their address but one thing they can key in HTML tags to change settings.

how do i detect those HTML tags but address should have magical quotes so that how can i fulfill both side ?

#2 lordphate

lordphate
  • Members
  • PipPipPip
  • Advanced Member
  • 154 posts

Posted 30 July 2006 - 04:42 AM

I use addslash? Or am i thinking of a wrong type of thing?

#3 effigy

effigy
  • Staff Alumni
  • Advanced Member
  • 3,600 posts
  • LocationIL

Posted 30 July 2006 - 05:16 PM

strip_tags + MySQL's real_escape_string.
Regexp | Unicode Article | Letter Database
/\A(e)?((1)?ff(?:(?:ig)?y)?|f(?:ig)?)\z/




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users