close ad
Install the LAtest Updates to Work with CC 2017 and CC 2018
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Captcha Not Restrictive

Thread began 3/30/2010 12:28 pm by dlovas275157 | Last modified 3/31/2010 11:00 pm by dlovas275157 | 1050 views | 4 replies |

dlovas275157

Captcha Not Restrictive

On my login page, I have applied CSS Form Builder in order to add a captcha to my login form.

However, the captcha is not validating properly. I can put anything in the captcha textfield and it will submit. It does not have to match. As long as I do not leave it blank, the form will submit.

Attached is my page code in a zip. Any help on how to fix is appreciated.

THanks.

D.

Attached Files
index.php.zip
Sign in to reply to this post

Jason ByrnesWebAssist

There is no validation on your page.


On the bindings panel, click the plus button and select the Session Variable. Set the name to:
captcha_Log_in_group_Security_code


On the server behaviors panel, click the plus button and select WA Validation toolkit -> Server Validations.


For validation type, chose like entry.

Click the lightning bolt next to server variable and chose the Log_in_group_Security_code form element.

Click the plus button to add it to the list of validations. Click the Lightning bolt next to same as and select the captcha_Log_in_group_Security_code session variable.

Sign in to reply to this post

dlovas275157

Jason,

I followed your instructions adding the WA Server Validation, but the captcha is still not validating properly (i can enter anything in the captcha field and it will pass).

Attached is my revised code.

Thanks again for your help.

Attached Files
index.php 2.zip
Sign in to reply to this post

Jason ByrnesWebAssist

the validation code is after the insert record code.


move lines 79 - 93:

php:
<?php 

if ($_SERVER["REQUEST_METHOD"] == "POST")  {
  
$WAFV_Redirect "";
  
$_SESSION['WAVT_index_Errors'] = "";
  if (
$WAFV_Redirect == "")  {
    
$WAFV_Redirect $_SERVER["PHP_SELF"];
  }
  
$WAFV_Errors "";
  
$WAFV_Errors .= WAValidateLE(((isset($_POST["Log_in_group_Security_code"]))?$_POST["Log_in_group_Security_code"]:"") . "",$_SESSION['captcha_Log_in_group_Security_code'] . "",true,1);

  if (
$WAFV_Errors != "")  {
    
PostResult($WAFV_Redirect,$WAFV_Errors,"index");
  }
}
?>




to line 40 so that the form will be validated before trying to insert the information into the database.

Sign in to reply to this post

dlovas275157

That worked!

Thanks again.

D.

Sign in to reply to this post

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...