*WITHOUT* using: ValidateRequest="False" for the whole page (or my whole site)....

  • Thread starter Thread starter \A_Michigan_User\
  • Start date Start date
A

\A_Michigan_User\

*WITHOUT* using: ValidateRequest="False" for the whole page (or my whole
site)....

How would I trap/detect that a textBox contains some illegal characters?

(I'm using asp.net v1.1 and vb.net)

Thanks.
 
How about using RegularExpressionValidator?

*WITHOUT* using: ValidateRequest="False" for the whole page (or my whole
site)....

How would I trap/detect that a textBox contains some illegal characters?

(I'm using asp.net v1.1 and vb.net)

Thanks.
 
Wouldn't I have to set ValidateRequest="False" for the whole page ... then
write my own RegEx code?

I'm trying to do this *WITHOUT* using: ValidateRequest="False" at all.

Like this:
Don't use ValidateRequest="False" at all..
Allow MS to check and generate the error.
I trap the error and can work around it.

I'm beginning to think that I'm stuck either way I do it:
I have to use the very dangerous "allow all characters in all textBoxes
on my entire page".
or
Forbid the dangerous characters ...but then everyone sees the ugly error
msg.

Wouldn't ValidateRequest have been infinitely more useful like this:
ValidateRequest="Remove" (Strip-out all the dangerous characters...
and no error is generated)
ValidateRequest="Trap" (Just give me a yes/no if this textBox contains
illegal chars... and I'll do the reset)

What are "illegal characters" anyway? MS seems to have an exact definition.
(Otherwise how could it generate the error?)
 
Back
Top