Forums / All Other Contributions/Addons / User Verification (Anti-Robot / CAPTCHA)

User Verification (Anti-Robot / CAPTCHA)

Views: 79,780

Results 61 to 80 of 192
1 Nov 2006, 6:39 PM
#61
tvadpro avatar

tvadpro

Zen Follower

Join Date:
Aug 2005
Location:
Cincinnati
Posts:
323
Plugin Contributions:
0

User Verification (Anti-Robot / CAPTCHA)

Woohoo! :laugh:

Upgraded to 1.3.6 today, then re-WinMerged those 4 CAPTCHA files:

  1. modules/pages/create_account/header_php.php
  2. modules/pages/create_account/jscript_form_check.php
  3. modules/create_account.php
  4. templates/template_default/templates/tpl_modules_create_account.php
    I was shocked and awed when I re-activated CAPTCHA, then filled out the new customer create-account form and it worked. Especially since I took several wild guesses in modifying create_account.php and tpl_modules_create_account.php. Maybe I did some copying last night in the wrong direction, but I suspect those files underwent several meaningful changes between 1.3.5 and 1.3.6.

Now ... how do we add this wonderful contribution to the tell-a-friend form? :lookaroun

3 Nov 2006, 1:09 PM
#62
x_vier avatar

x_vier

New Zenner

Join Date:
Oct 2006
Location:
Belgium
Posts:
39
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

Hello,

The Captcha is a real added value to the Zen Cart.

I'm new to this forum and I'm trying to make a new shop with Zen Cart (https://www.mindex.be/anatest%29. Until now it works fine.
I'm a software newby so I must rely on the experience of the people in this forum. If it's permitted?

With phpMyadmin I uploaded the captcha.sql file with no problems.
On the website there the following error message:

1146 Table 'anamorf_zc1.zen_anti_robotreg' doesn't exist
in:
[DELETE FROM zen_anti_robotreg WHERE timestamp < '1162555155' OR session_id = 'bd01349c14acb00239260c2f5ae5f147']

How can that be repaired?

Thank you for your help,

Xavier

3 Nov 2006, 4:20 PM
#63
x_vier avatar

x_vier

New Zenner

Join Date:
Oct 2006
Location:
Belgium
Posts:
39
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

Hello,

In the archives of this forum I found a contribution about this issue and it helped me.

The solution I found was add zen_ to the table names.
Then I created a new .sql file with only the instructions to create the new anti_robotreg table. This file was copied to the "SQL Query Executor" and send.
Now it works for the login page.

it's really a great thing!!!

Next step is to add the Captcha to the other applications such as tell-a-friend and contact us.

Anyone any experience or ideas how that should be done?

Thanks,

Xavier

9 Nov 2006, 4:45 AM
#64
funkey avatar

funkey

New Zenner

Join Date:
Jul 2005
Posts:
85
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

Hi Xavier,

The CAPTCHA code SQL file comes without a table prefix because that's the default for new Zen-Cart 1.3.x installs. If you have a Zen-Cart setup with a table prefix (such as yours) you'll need to make that change manually before installing the SQL code.

I've added a small note to the new 1.3.6 release clarfiying that for new users, so they can benefit from your experience.

Cheers,

Paul

X@vier:

Hello,

In the archives of this forum I found a contribution about this issue and it helped me.

The solution I found was add zen_ to the table names.
Then I created a new .sql file with only the instructions to create the new anti_robotreg table. This file was copied to the "SQL Query Executor" and send.
Now it works for the login page.

it's really a great thing!!!

Next step is to add the Captcha to the other applications such as tell-a-friend and contact us.

Anyone any experience or ideas how that should be done?

Thanks,

Xavier

9 Nov 2006, 4:51 AM
#65
funkey avatar

funkey

New Zenner

Join Date:
Jul 2005
Posts:
85
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

Just to let everyone know, an updated copy of the CAPTCHA modification that works out-of-the-box with 1.3.6 has just been uploaded to the contributions area.

Existing users of the code don't need to do anything with the .SQL file, just drop-in the PHP files as required and you're good to go.

Aside from the code changes, the SQL file itself has been altered quite a bit to work around broken PHP installations -- which should mean it is a lot easier for new users to install first time around.

Cheers,

Paul

9 Nov 2006, 3:17 PM
#66
tvadpro avatar

tvadpro

Zen Follower

Join Date:
Aug 2005
Location:
Cincinnati
Posts:
323
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

funkey:

an updated copy of the CAPTCHA modification that works out-of-the-box with 1.3.6 has just been uploaded to the contributions areal
Thanks Paul! If I didn't want to go hunting for it, would I find the newest CAPTCHA via this link? :smile:
Sean

9 Nov 2006, 9:18 PM
#67
siddg avatar

siddg

New Zenner

Join Date:
Oct 2006
Posts:
7
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

funkey:

I'm not really sure why, but something in my code seems to trip up the htmlspecialchars code in the /admin/configuration.php file.

I've gone through the SQL file -- and several threads on the forum and come up with a version that seems to install on both Windows PHP4 and a BSD PHP5 installation of Zen-Cart 1.3.5.

Can the people who reported trouble with the eval() problem above try the attached .sql file (again, cut-and-paste, don't upload it) and let me know if it's any better?

For reference, i'm developing this code on an PHP5 installation with magic_gpc_quotes turned off.

Cheers,

Paul

Paul: I have upgraded to 1.3.6 seamlessly except of CAPTCHA working.
The images just refuse to appear on the login/create_account page. I have followed the instructions to the tee.

Then my eyes went on magic_gpc_quotes per your post above, on my windows server it is on.

The funniest part is no images or input field or description shows up...but i get the message stack stating no entry has been made in the captcha box upon registration..

need your help...
thanks
sid

9 Nov 2006, 10:21 PM
#68
x_vier avatar

x_vier

New Zenner

Join Date:
Oct 2006
Location:
Belgium
Posts:
39
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

Thanks, Paul, for the upgrade.

Next step is to integrate the captcha in other modules as Subscribe or tell-a- friend.
Any plans?

Xavier

14 Nov 2006, 5:33 AM
#69
pensive612 avatar

pensive612

Zen Follower

Join Date:
May 2006
Posts:
313
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

SiddG,

I had the same problem, of the actual CAPTCHA table not showing up. I then, uploaded the the includes/templates/template_default/templates/tpl_modules_create_account.php to both the templates default and my override. and it worked perfect. and that was the only change i made.

hope that helps..!

  • pensive612
24 Nov 2006, 2:55 PM
#70
cardell avatar

cardell

New Zenner

Join Date:
Nov 2006
Location:
Melbourne, Australia
Posts:
18
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

Hi,

This module has been working fine for me, but I noticed that some of my [new] customers were having difficulty creating accounts.

I decided to temporarily disable this module. I turned it off in admin and then I noticed on the login/create account page (under the newsletter subscription) I am getting a blank <fieldset> tag (like SiddG mentioned in post #48) . It looks bad.

I am running zencart 1.3.5 (haven't updated to 1.3.6 yet). Has this been fixed in the newer (1.3.6 compatible) version of this module?

Alternatively, is there some code I can add somewhere?

Thanks

Stuart

Our Zen site: **The Organic Outlet**
'Certified organic foods products
& beverages at affordable prices'

27 Nov 2006, 12:32 AM
#71
funkey avatar

funkey

New Zenner

Join Date:
Jul 2005
Posts:
85
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

cardell:

Hi,

This module has been working fine for me, but I noticed that some of my [new] customers were having difficulty creating accounts.

I decided to temporarily disable this module. I turned it off in admin and then I noticed on the login/create account page (under the newsletter subscription) I am getting a blank <fieldset> tag (like SiddG mentioned in post #48) . It looks bad.

I am running zencart 1.3.5 (haven't updated to 1.3.6 yet). Has this been fixed in the newer (1.3.6 compatible) version of this module?

Alternatively, is there some code I can add somewhere?

Thanks

Hi Stuart,

In a vanilla install of 1.3.6, I can see an empty </fieldset> tag if I turn off "Account Validation" in the admin -- but no actual <fieldset> tag.

Do you have a screenshot or some code I can use to track it down, my pages look normal (even with the empty closing tag).

Cheers,

Paul

27 Nov 2006, 4:04 AM
#72
woodymon avatar

woodymon

Totally Zenned

Join Date:
Sep 2004
Posts:
2,309
Plugin Contributions:
1

Re: User Verification (Anti-Robot / CAPTCHA)

cardell:

I turned it off in admin and then I noticed on the login/create account page (under the newsletter subscription) I am getting a blank <fieldset> tag (like SiddG mentioned in post #48) . It looks bad.

I am running zencart 1.3.5 (haven't updated to 1.3.6 yet). Has this been fixed in the newer (1.3.6 compatible) version of this module?

When you installed the captcha mod did you upload the provided override for tpl_modules_create_account.php to your custom template directory?

I do not see the fieldset tags display in the browser on the create acct/login page (/index.php?main_page=login) when captcha is disabled in admin.

However as Paul stated when viewing the source in the browser I do see a lone closing </fieldset> tag all by all itself, where the captcha code would be rendered. It is errant but shouldn't hurt anything.

Which browser are you noticing issue?

I'm running ZC 1.36 fresh install with captcha_0.99.136 mod. Viewing page in Firefox 2.0.

BTW, what kind of errors are your customers observing when captcha is enabled?

Woody

27 Nov 2006, 5:13 AM
#73
funkey avatar

funkey

New Zenner

Join Date:
Jul 2005
Posts:
85
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

Woodymon:

When you installed the captcha mod did you upload the provided override for tpl_modules_create_account.php to your custom template directory?

I do not see the fieldset tags display in the browser on the create acct/login page (/index.php?main_page=login) when captcha is disabled in admin.

However as Paul stated when viewing the source in the browser I do see a lone closing </fieldset> tag all by all itself, where the captcha code would be rendered. It is errant but shouldn't hurt anything.

Which browser are you noticing issue?

I'm running ZC 1.36 fresh install with captcha_0.99.136 mod. Viewing page in Firefox 2.0.

BTW, what kind of errors are your customers observing when captcha is enabled?

Woody

Just on that closing </fieldset> -- it appears to be a problem with the core Zen-Cart code, rather than anything the CAPTCHA modification has added, as it comes up on a fresh install of the original zipfile from sourceforge too.

My code, looks a bit like:

@@ -183,6 +183,56 @@
 </fieldset>
 
 <?php
+if (ACCOUNT_VALIDATION == 'true') {
+?>
+
+<?php
+if (strstr($_SERVER['REQUEST_URI'],'create_account') && CREATE_ACCOUNT_VALIDATION == 'true' || strstr($_SERVER['REQUEST_URI'],'login') && LOGIN_VALIDATION == 'true') { 
+?>
+
+<?php
+  if ($is_read_only == false || (strstr($_SERVER['REQUEST_URI'],'create_account')) || (strstr($_SERVER['REQUEST_URI'],'login'))) {
+       $sql = "DELETE FROM " . TABLE_ANTI_ROBOT_REGISTRATION . " WHERE timestamp < '" . (time() - 3600) . "' OR session_id = '" . zen_session_id() . "'";
+       if( !$result = $db->Execute($sql) ) { die('Could not delete validation key'); }
+       $reg_key = generate_captcha_code();
+       $sql = "INSERT INTO ". TABLE_ANTI_ROBOT_REGISTRATION . " VALUES ('" . zen_session_id() . "', '" . $reg_key . "', '" . time() . "')";
+       if( !$result = $db->Execute($sql) ) { die('Could not check registration information'); }
+?>
+
+
+<fieldset>
+<legend><?php echo CATEGORY_ANTIROBOTREG; ?></legend>
+<label class="inputLabel" for="antirobotreg"><?php echo ENTRY_ANTIROBOTREG ?></label>
+
+<?php
+$validation_images = '';
+for($i = 0; $i < ENTRY_VALIDATION_LENGTH; $i++)
+    {
+    $parse_image = 'validation/validation_' . $reg_key{$i} . '.gif';
+    $parse_image_alt = $reg_key{$i};
+    $validation_images .= zen_image(DIR_WS_IMAGES . $parse_image, $parse_image_alt);
+    }
+    echo '<div class="centered">';
+    echo $validation_images . '<br />';
+    echo '</div>';
+?>
+
+<?php echo zen_draw_input_field('antirobotreg','', 'id="antirobotreg"') . (zen_not_null(ENTRY_ANTIROBOTREG) ? '<span class="alert">' . ENTRY_ANTIROBOTREG_TEXT . '</span>': ''); ?>
+<br class="clearBoth" />
+
+<?php
+    }
+?>
+
+<?php
+    }
+?>
+
+<?php
+    }
+?>

The first </fieldset> comes from the stock code, everything with a + is my changes -- and the only additional <fieldset> (line 202) i've added (which probably could do with a closing tag around line 206 too, i'll make sure I add one for the next release.) is safely caught within the initial if().

Paul

27 Nov 2006, 7:46 AM
#74
gwaitsi avatar

gwaitsi

New Zenner

Join Date:
Oct 2006
Posts:
48
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

I installed the lastest version on zencart 1.3.6.

I also have the split login mod installed but have removed it for testing purposes.

In either case, the login validation doesn't work. The catcha box is not displayed at all.

This does work for the account creation screen with either the original login screen or the split screen mod.

Great addition to the zencart. Should be standard in the buid.

Any help appreciated.

Cheers

27 Nov 2006, 8:58 AM
#75
funkey avatar

funkey

New Zenner

Join Date:
Jul 2005
Posts:
85
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

GwaiTsi:

I installed the lastest version on zencart 1.3.6.

I also have the split login mod installed but have removed it for testing purposes.

In either case, the login validation doesn't work. The catcha box is not displayed at all.

This does work for the account creation screen with either the original login screen or the split screen mod.

Great addition to the zencart. Should be standard in the buid.

Any help appreciated.

Cheers

Two things:

  • Did you enable the "Activate Validation on Login Page" in the Admin? (It should be on by default)

  • If you have a custom template installed, did you copy the tpl_modules_create_account.php file to your templates/ directory?

Paul

27 Nov 2006, 9:11 AM
#76
gwaitsi avatar

gwaitsi

New Zenner

Join Date:
Oct 2006
Posts:
48
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

thanks for the reply.

Answer to both is yes.

Activate Validation of Login Page - has no effect,
while Activate Validation and Activate Validation on Login Page both work.

As previously stated, I am using the "Split Login" mod and have tried with the default configuration and with the Split Login mod, never works.

Point to add:
With the default login screen (login and account create on same page), the catcha box appears at the bottom of the page but only works for the account creation function. normal login does not require it.

With the split login screen mod, the catcha box only appears on the account creation page and not on the main login page.

you can see an example at www.greatsouthernwines.com

thanks again for any help

27 Nov 2006, 9:43 AM
#77
funkey avatar

funkey

New Zenner

Join Date:
Jul 2005
Posts:
85
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

GwaiTsi:

thanks for the reply.

Answer to both is yes.

Activate Validation of Login Page - has no effect,
while Activate Validation and Activate Validation on Login Page both work.

As previously stated, I am using the "Split Login" mod and have tried with the default configuration and with the Split Login mod, never works.

Point to add:
With the default login screen (login and account create on same page), the catcha box appears at the bottom of the page but only works for the account creation function. normal login does not require it.

With the split login screen mod, the catcha box only appears on the account creation page and not on the main login page.

you can see an example at www.greatsouthernwines.com

thanks again for any help

Hmmm, i'd hazard a guess this has to do with the way the "split login" modification was written.

I've only taken a quick look, but the CAPTCHA module does most of it's 'user-based' work in the tpl_modules_create_account.php file, which is usually required by the login page, but the "split login" mod seems to comment out, which would explain why the code is never being run by the tpl_login_default.php file.

I'll take a closer look later, you could probably get it to work by cutting-and-pasting the code I posted above (basically, the changes that are needed for the tpl_modules_create_account file) into the tpl_login_default.php file in the relevant spots, but I wouldn't advise it unless you were certain where things are supposed to go.

Cheers,

Paul

27 Nov 2006, 11:48 AM
#78
cardell avatar

cardell

New Zenner

Join Date:
Nov 2006
Location:
Melbourne, Australia
Posts:
18
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

Hi funkey & Woodymon,

I'm sorry if I didn't make this clear in my original post......what I am seeing on my page (in Internet Explorer 6) is an empty border at the bottom of my login screen just before the submit button. I am not seeing any html codes/instructions.

My login page is at:
https://www.theorganicoutlet.com.au/index.php?main_page=login

When I installed the CAPTCHA mod, I did make sure I uploaded the provided override for tpl_modules_create_account.php to my custom template directory.

I hadn't thought to try viewing the page with another browser, so I downloaded Mozilla Firefox today and the empty border did not show up in it. It looked perfect!?:laugh:

I believe the CAPTCHA module works perfectly on my site (because I tested it) but....after I installed it, I noticed a few [new] customers (I have the user tracking module installed) hitting my login/create account page over and over again (one customer did 7 times!) then leaving my site without the items they had put in their shopping carts.:shocking:

My intention was to turn the CAPTCHA module off for a week or two and observe whether it happened again.

Thanks for your help.:smile:

Stuart

Our Zen site: **The Organic Outlet**
'Certified organic foods products
& beverages at affordable prices'

28 Nov 2006, 3:24 PM
#79
flashpoint avatar

flashpoint

New Zenner

Join Date:
May 2006
Posts:
14
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

greetings,
i installed CAPTCHA verbatim to the installation procedures provided.

i have 2 problems?

  1. I don't see the Configuration Options when i click on it in the Admin/Configuration menu
  2. Validation works fine in Firefox, but not internet explorer. I get 4 or 5 blocks that are supposed to be images I presume.

Any ideas on how to resolve these issues?

Thank you

just another day in paradise

29 Nov 2006, 12:19 AM
#80
flashpoint avatar

flashpoint

New Zenner

Join Date:
May 2006
Posts:
14
Plugin Contributions:
0

Re: User Verification (Anti-Robot / CAPTCHA)

ok, I was able to resolve the issue in Internet Explorer. Apparently, I neglected to upload the Images and to create a "validation" sub-directory.

however, I still do not see the CAPTCHA configuration options under Admin/Configuration.

Thanks.

just another day in paradise