how can i check session value in regex

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
manojsemwal1
Forum Contributor
Posts: 217
Joined: Mon Jun 29, 2009 4:13 am
Location: India

how can i check session value in regex

Post by manojsemwal1 »

i have a form where i am using captcha image .when the user will fill up the form it should be fill the security code appearing in captcha image. iam using regex validation so how can i validate user does not blank the filled and the captcha image should be matched by user entered text.
manojsemwal1
Forum Contributor
Posts: 217
Joined: Mon Jun 29, 2009 4:13 am
Location: India

Re: how can i check session value in regex

Post by manojsemwal1 »

send some answer
User avatar
flying_circus
Forum Regular
Posts: 732
Joined: Wed Mar 05, 2008 10:23 pm
Location: Sunriver, OR

Re: how can i check session value in regex

Post by flying_circus »

manojsemwal1 wrote:send some answer
Since you asked nicely...

Why are you using a regex? Either it matches or it doesn't, so why dont you just compare the two values instead?
manojsemwal1
Forum Contributor
Posts: 217
Joined: Mon Jun 29, 2009 4:13 am
Location: India

Re: how can i check session value in regex

Post by manojsemwal1 »

iam using regex because my form is having regex validation so iam using captcha for security purpose so i need to compare the value which is filled by user and captcha image
User avatar
timWebUK
Forum Contributor
Posts: 239
Joined: Thu Oct 29, 2009 6:48 am
Location: UK

Re: how can i check session value in regex

Post by timWebUK »

You don't need to use to regex. You just need to compare the user entered value, with the captcha image value stored in the session.
Post Reply