[ Please type your reply *below* the quoted part of the message you
are replying to. ]

Chris Welch wrote:
Gunnar Hjalmarsson wrote:
Chris Welch wrote:
I have a dilemma, I am processing CGI forms and I need to come
up with a regex that will accept HTML entities (i.e., " or
{),

Your description makes me fear that you are somewhat off track. *Why* would you need such a regex?

If you explain more about the context, it would be easier to
advise.

Basically I am going to turn some funny characters into HTML entities using the aforementioned HTML::Entities so I can display them in a HTML page. I therefore need to accept them, but also the other chars.

I can understand that you want to validate the other ("funny") characters, but I don't understand why your validation regex would need to include HTML entities. Isn't HTML encoding something *you* do, before display but after validation?

As far as I am aware HTML::Entities will only turn characters into
their HTML entity equivalent and vice versa, depending on the
function used, correct?

Yes.

--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>




Reply via email to