My local dev server is set-up with register_globals disabled (just like the production server I want to run the mod on). Could this be cause to my issue?
Megaman, do you have register globals on or off on your demo site?
Woody
Printable View
My local dev server is set-up with register_globals disabled (just like the production server I want to run the mod on). Could this be cause to my issue?
Megaman, do you have register globals on or off on your demo site?
Woody
v 2.3 16.03.2007 10:51
1. Some Admin configuration adjustments added;
2. Remove non CAPTCHA updated code from Review Write page;
3. Add gif support;
Ha! I figured that much out. Just was inquiring if anyone had ideas how to resolve. My local server is set-up to emulate my production server on webhost. If it does not run on my local server then it will not run on web host. But to be certain I just installed a fresh Zen cart on same host machine production shop is running on and installed previous version of your mod (v2.2) and same exact errors observed. Hosting provider grepped through the server logs and did not find anything unusual but observed same errors in the server error log. He asked me if the mod requires register_globals enabled. I stated I did not know but probably not as the mod developer is super security conscious.
How would I test if CAPTCHA mod requires register_globals?
OK I will install and test the new version.
Anyone have ideas what might contribute to above reported errors? Thanks for any recommends.
Woody
Tips:
Script for testing CAPTCHA:
Code:<?php
require('includes/application_top.php');
require(DIR_WS_CLASSES . 'captcha.php');
$captcha = new captcha();
if(isset($_POST['action']) && $_POST['action'] == 'GO') {
if($captcha->validateCaptchaCode())
echo 'You enter VALID code - "' . $_POST["captcha"] . '"';
else
echo 'You enter INVALID code - "' . $_POST["captcha"] . '"';
}
?>
<form action="<?php echo $PHP_SELF; ?>" method="post">
<?php
// BOF Captcha
if(is_object($captcha)) {
?>
<?php echo $captcha->img(); ?>
<?php echo $captcha->redraw_button(BUTTON_IMAGE_CAPTCHA_REDRAW, BUTTON_IMAGE_CAPTCHA_REDRAW_ALT); ?>
<br class="clearBoth" />
<label for="captcha"><?php echo TITLE_CAPTCHA; ?></label>
<?php echo $captcha->input_field('captcha', 'id="captcha"') . ' <span class="alert">' . TEXT_CAPTCHA . '</span>'; ?>
<br class="clearBoth" />
<?php
}
// EOF Captcha
?>
<input type="submit" name="action" value="GO" />
</form>
Woody!
I use this CAPTCHA more than six months on different hosting. And only you have so problems.
How can I help you if you can't give me any usefull information or url for you test site?
Andrew,
Thanks for the follow-up and the upgrades!I discovered there is one diff between the two servers. The production shop was recently moved to a server with different version of PHP. Not sure why I forgot something so significant.
Anyway, the good news is I now have your new v.2.3 CAPTCHA working on PHP 4.4.4. I see many nice new v2.3 options in admin!
But mod v2.2 is still not working on the server running PHP 5.1.6. Thus I will try your test script and also install new mod version 2.3.
Woody
Installed v.2.3 (on server running PHP 4.4.4)
Good News: I can change the width and height of the background image and change the code length. And the shadows appear behind the characters. And the random diagonal lines appear behind the characters.
Bad News: The redraw button does not respond. And the characters are small and vertical, and not rotated as expected. In admin (Config >CAPTCHA) I changed the max and min "chars" sizes to no effect.
I've tried all three image type options (png, jpeg, gif) to same effect.
All of the above applies to both the contact_us and login page.
Before I spend too much time investigating thought I'd check to see if others observe the same with v2.3.
Woody
Thanks again for the test script Andrew.
I installed both the test script and v2.3 on on Zen Cart 1.37 on a host running PHP 4.4.4 and all is good (well a few errors as reported above but the image displays in both Firefox and IE6).
But the test script does not display image on Zen Cart 1.37 running on PHP 5.1.6.
Not wanting to jump to conclusion but is there possibly a PHP version compatibility issue here?
Could others whom have success with the mod and/or success running the test script above, please post their PHP version? Thanks.
Woody
v 2.4 20.03.2007 11:39
1. Support for GD 1;
2. Use of a class dir instead of function opendir;
Woody!
Test this version.