Forums / All Other Contributions/Addons / CAPTCHA Anti-Robot Mod

CAPTCHA Anti-Robot Mod

Views: 37,328

Results 121 to 140 of 186
8 Jun 2012, 5:13 PM
#121
rixstix avatar

rixstix

Totally Zenned

Join Date:
Aug 2009
Location:
North Idaho, USA
Posts:
2,015
Plugin Contributions:
0

CAPTCHA Anti-Robot Mod

It doesn't play nice with customer login in my test install. It plays nice with the default contact us but not with a 2nd, separate instance of contact us that is a feature of the template we are currently configuring but that's a horse of a different color.

Login just give a blank screen. Restore backup and login functions.

Default setup with no addons installed yet other than a few templates for testing. I just dropped the files into place without doing anything that might have been said in the readme file other than changing template name and admin folder name.

I won't have time until later today to look more deeply.

Rick
RixStix (dot) com
aka: ChainWeavers (dot) com

8 Jun 2012, 5:58 PM
#122
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,848
Plugin Contributions:
17

Re: CAPTCHA Anti-Robot Mod

ATSWorld
First of all, thanks for letting us know the sql worked.
Along with RixStix ,you may have made the cardinal mistake of not reading the readme throughout. My mother used to call it "jumping on your horse and riding madly off in all directions."
The readme says a couple of very important things.

  1. The included files that overwrite core files DO NOT contain ANY changes other than those specifically for CAPTCHA 1.5.
  • If you had made any other changes to those files with another mod, those changes are now gone.
  • The readme specifically reminds you to backup, WinMerge (or something similar), and THEN upload.
  • Apologies if "I didn't delete the old files just over wrote" actually meant you check first to make sure you weren't wiping a previous mod's info from your site.
  1. The files included are meant to be used with Zen-Cart v1.5.0 and its basic install.
  • Again, the readme states that the login works with the split-login set to true. (I did not work on this as all our sites use split login. Maybe in the near future.)
  • Trying to create a version that will work with FEC, LM, or any other mod that involves a submission form would bloat the mod beyond imagination. If no one is reading the docs now, I can only imagine the size of the support thread for a bloated mod. (Ultimate SEO comes to mind).
    One of the things about open source is that you are free to change things to suit your needs. We all do it with just the basic cart or else every Zen Cart site would have the "Welcome" notice. From the simple beginnings to the adding of mods, pages, etc; we all strive to get it just right and maybe learn something along the way.
    On the subject of Links Manager, CAPTCHA adds the following to contact_us (includes\templates\YOUR_TEMPLATE\templates\tpl_contact_us_default.php):> <!--START CAPTCHA INPUT HERE -->
<?php if (ACCOUNT_VALIDATION == 'true' && CONTACT_US_VALIDATION == 'true') { ?> <?php if (strstr($_SERVER['REQUEST_URI'],'contact_us') && CONTACT_US_VALIDATION == 'true' || strstr($_SERVER['REQUEST_URI'],'login') && LOGIN_VALIDATION == 'true') { ?> <?php if ($is_read_only == false || (strstr($_SERVER['REQUEST_URI'],'contact_us')) || (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 } ?> </fieldset> <!-- END CAPTCHA INPUT -->This comes after a </filedset> and before the <div class="buttonRow forward....

You might try entering the above code around line 158 of the includes\templates\YOUR_TEMPLATE\templates\tpl_lings_submit_default.php

MAKE SURE YOU BACK EVERYTHING UP FIRST!!!!

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

8 Jun 2012, 6:20 PM
#123
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,848
Plugin Contributions:
17

Re: CAPTCHA Anti-Robot Mod

RixStix:

It doesn't play nice with customer login in my test install. ... I just dropped the files into place without doing anything that might have been said in the readme file other than changing template name and admin folder name.As noted with ATSWorld, I can't imagine anyone doing a mod install as either of you have done.
Well, maybe back in 2004 as a noob, I might have jumped in with both feet.
I'm harping on the both of you ONLY to prevent others from trying this the same way. Did either of you have any concerns when your FTP program said it was going to overwrite files? I hope your FTP program is not set to automatically overwrite.
Maybe you both were doing this on a test site with total backup. If so, that's your choice but, each time we state something in the forum we are leaving a trail that others will follow.
<petPeeves>

  1. Giving shortcuts to some procedure that is detailed in the tutorials/FAQs, or docs, or readme.
  2. Posting an "I've got the exact same problem" post rather than a new thread.
  3. Not following the posting tips (see number 2)
  4. Obviously failing to do a search before posting (see number 2)
  5. Thinking that the virtual shrink-wrap on the tutorials/FAQs, docs, or readme is impervious to all, including super-heroes.
  6. Folks who want us to feed them a fish rather than asking how to fish.
    </petPeeves>
    After all that, yes I did see in the CAPTCHA thread that folks were having a problem with plain login but, I did not see any solution provided. As stated in the readme, we do not use any of the logins other than the split-login. However, I will take another look at what can be done before submission.
    I humbly accept any suggestions on that fishing expedition.:P

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

8 Jun 2012, 8:00 PM
#124
rixstix avatar

rixstix

Totally Zenned

Join Date:
Aug 2009
Location:
North Idaho, USA
Posts:
2,015
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

Did either of you have any concerns when your FTP program said it was going to overwrite files?
Not really, since it was a default install with no mods yet installed. On my live sites, Yes, I would have looked more closely.

Maybe you both were doing this on a test site with total backup. If so, that's your choice but,

That sounds like that having a total backup even for a test site is a bad thing, but I know that isn't the intention.:smile:

That's why I said that I hadn't read the readme but assumed that since I was dropping it into a default v1.5 install that I wouldn't get caught with my drawers around my knees or needed to worry about checking/merging files. That'll teach me not to read. I only consider myself a step and a half above a noob but know that "Backup is my friend". Sorry, I thought that I was helping but am also smart enough to realize that I only know enough to be dangerous.

Yes, I always use my test domain just in case something goes unexpected but even then, a backup is the last click immediately prior to uploading anything new.

Rick
RixStix (dot) com
aka: ChainWeavers (dot) com

8 Jun 2012, 8:57 PM
#125
rixstix avatar

rixstix

Totally Zenned

Join Date:
Aug 2009
Location:
North Idaho, USA
Posts:
2,015
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

Just installed again, after reading the readme. Didn't need to change a thing. Split Login was already true.

All seems to be playing well together this time. Contact and Create Account captcha both functioning as expected.

Rick
RixStix (dot) com
aka: ChainWeavers (dot) com

8 Jun 2012, 9:41 PM
#126
andy_c27 avatar

andy_c27

Zen Follower

Join Date:
Oct 2010
Location:
United Kingdom
Posts:
477
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

lol not a problem :) ... I had a full site backup anyway ..(I make 1 once a week) as for the fec and links was only asking :P lol ..I am happy as it is right now as was mostly concerned about spamming messages that is on the increase ..this will put a stop to it I hope
but thanks for the update much appreciated

9 Jun 2012, 10:42 PM
#127
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,848
Plugin Contributions:
17

Re: CAPTCHA Anti-Robot Mod

Sorry for the rant.

My point was really meant to be that NO ONE should EVER upload a mod without checking everything out first. It doesn't matter if it's a clean install with three backups. You just don't know what the mod author had in mind. Some will include a snippet of code to be inserted in a core file.

I certainly wouldn't overwrite any core file with my FTP till I found out what was going on.

That said, I'm still open for suggestions on the login versus split-login settings.

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

10 Jun 2012, 5:50 AM
#128
fandara avatar

fandara

New Zenner

Join Date:
May 2012
Location:
Venezuela
Posts:
5
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

Hello, I have a similar problem. Install this contribution and works great except for create account. The box does not appear at the end, however, after a client has sent your registration, by magic, the captcha is asked not previously revealed.

Anyone know what may be happening, I've reviewed a thousand times the installation and everything is fine.

Thanks in advance.

10 Jun 2012, 5:51 AM
#129
fandara avatar

fandara

New Zenner

Join Date:
May 2012
Location:
Venezuela
Posts:
5
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

fandara:

Hello, I have a similar problem. Install this contribution and works great except for create account. The box does not appear at the end, however, after a client has sent your registration, by magic, the captcha is asked not previously revealed.

Anyone know what may be happening, I've reviewed a thousand times the installation and everything is fine.

Thanks in advance.

http://www.ojovel.com.ve/cctv/index.php?main_page=login

10 Jun 2012, 6:06 AM
#130
coopco avatar

coopco

New Zenner

Join Date:
Jun 2006
Location:
Sea Lake, Australia
Posts:
81
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

Are you using the split login as in the readme?

10 Jun 2012, 10:13 AM
#131
andy_c27 avatar

andy_c27

Zen Follower

Join Date:
Oct 2010
Location:
United Kingdom
Posts:
477
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

Anyway I tried the coding/place you suggested and it didn't like it ,so have removed it ..thanks for trying though

10 Jun 2012, 9:58 PM
#132
dbltoe avatar

dbltoe

Totally Zenned

Join Date:
Jan 2004
Location:
N of San Antonio TX
Posts:
9,848
Plugin Contributions:
17

Re: CAPTCHA Anti-Robot Mod

It was a quick guess. Since it's one of Clyde's mods, I feel I owe it to him to look a little further. If it is added to CAPTCHA, it will be an option for folks to find in the readme.:shocking:
Now to find some time this week.

Need a hand with Zen Cart? Hire the team at myZenCartZone.com for upgrades, repairs, and custom plugins.
Zen Cart Certified hosting at myZenCartHost.com

13 Jun 2012, 4:04 PM
#133
andy_c27 avatar

andy_c27

Zen Follower

Join Date:
Oct 2010
Location:
United Kingdom
Posts:
477
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

that would be fine by me ....Clyde is sorely missed as I use a lot of his add ons

11 Oct 2012, 3:50 PM
#134
hockey2112 avatar

hockey2112

Zen Follower

Join Date:
Jun 2010
Posts:
204
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

I installed this mod (http://www.zen-cart.com/downloads.php?do=file&id=215) on a ZC 1.39h website. It does show the captcha on the Create Account page, but it does NOT show it on the Login/Create account page (http://mywebsite.com/index.php?main_page=login). How can I get it to show up on that page as well?

Thanks!


I should have done a bit more searching before posting. The solution is to use the split login setting in Configuration>Layout Settings.

24 Oct 2012, 4:36 AM
#135
timbojrjr1 avatar

timbojrjr1

New Zenner

Join Date:
Oct 2012
Posts:
23
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

I finally got this installed and now I try to turn it on through my admin. I go to Configuration-> Captcha Validation and it shows Sitemap XML. It's like my Captcha Validation points to Sitemap XML also under configuration. Does anyone know why this would be. Thanks for any help.

24 Oct 2012, 5:00 AM
#136
timbojrjr1 avatar

timbojrjr1

New Zenner

Join Date:
Oct 2012
Posts:
23
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

Ok I got it installed I messed up on phpMyAdmin side and took the last GID and Sort order from there and it should be from configuration_pages. Now it is just blank I will sort through this thread to see for any help with this.

24 Oct 2012, 8:09 PM
#137
timbojrjr1 avatar

timbojrjr1

New Zenner

Join Date:
Oct 2012
Posts:
23
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

I let it sit overnight and I still have a blank screen in the admin side of this captcha mod. Does anyone know why this would be?

27 Oct 2012, 1:01 AM
#138
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: CAPTCHA Anti-Robot Mod

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

29 Oct 2012, 5:52 AM
#139
timbojrjr1 avatar

timbojrjr1

New Zenner

Join Date:
Oct 2012
Posts:
23
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

I don't know what is going on I re-uploaded all the files and still the same thing. I checked to make sure everything was there through my cpanel. I uploaded using Filezilla. It would be easier if I could get an error from this but nothing is showing up in the logs folder. I noted in your tpl file you don't have

<!--START CAPTCHA INPUT HERE --> <?php if (ACCOUNT_VALIDATION == 'true' && CONTACT_US_VALIDATION == 'true') { ?> <?php if (strstr($_SERVER['REQUEST_URI'],'contact_us') && CONTACT_US_VALIDATION == 'true' || strstr($_SERVER['REQUEST_URI'],'login') && LOGIN_VALIDATION == 'true') { ?> <?php if ($is_read_only == false || (strstr($_SERVER['REQUEST_URI'],'contact_us')) || (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 } ?> <!-- END CAPTCHA INPUT -->

Well at least most of this. It is in the other tpl files maybe this is causing a problem. Maybe I should try another captcha mod? Does english.php on the admin side create all the listings for this mod on the admin side. True/False on each page to turn on the mod on that page.

29 Oct 2012, 6:01 PM
#140
firstcapitalfirearms avatar

firstcapitalfirearms

Zen Follower

Join Date:
Sep 2012
Posts:
196
Plugin Contributions:
0

Re: CAPTCHA Anti-Robot Mod

I believe I have installed Captcha correctly but when I click on Captcha Validation in the Admin / Config it pulls up Easy Populate instead. What have I done wrong or forgot to do. Any help is greatly appreciated. I am using ZC 1.5

Thanks
Mark