Zen Cart Logo
Forums / All Other Contributions/Addons / reCaptcha addon not showing in page

reCaptcha addon not showing in page

Views: 8,305

Results 21 to 40 of 49
21 May 2012, 1:27 AM
#21
scriptjunkie avatar

scriptjunkie

Totally Zenned

Join Date:
Jul 2008
Posts:
772
Plugin Contributions:
0

reCaptcha addon not showing in page

I'm running ZC v1.5.0 and I just installed reCaptcha v1.3.2, revision ce41a91dfcf9 which I downloaded from https://bitbucket.org/pickupman/zencart-recaptcha/downloads

Per the instructions, it says to log in to your admin once the files have been uploaded and click the install button at the top of the page. When I went to my admin login page, a blank page was loaded - preventing me from entering my login credentials. The error log generated states the following:

[18-May-2012 17:06:21] PHP Parse error: syntax error, unexpected T_IF in /admin/includes/init_includes/init_reloadedstack.php on line 1

Can you please advise?

21 May 2012, 12:53 PM
#22
pickupman avatar

pickupman

New Zenner

Join Date:
Jun 2009
Posts:
83
Plugin Contributions:
2

Re: reCaptcha addon not showing in page

@ScriptJunkie
Try reuploading the file, as I don't see any syntax errors in the file that would cause that error. If that doesn't work, try removing the comment block (lines 2-5) and upload without the comment block.

Sorry I didn't get your PM. I didn't have notifications for that turned on somehow.

21 May 2012, 1:29 PM
#23
scriptjunkie avatar

scriptjunkie

Totally Zenned

Join Date:
Jul 2008
Posts:
772
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

No worries on the PM - should have posted here in the first place :smile:

Ok, removed comment block, but no joy. New error is:

PHP Parse error: syntax error, unexpected '{' in admin/includes/init_includes/init_reloadedstack.php on line 1

The code is as follows:

<?phpif (isset($_SESSION) AND is_numeric($_SESSION['admin_id']) AND is_object($reloadedStack) ){	foreach ($reloadedStack->errors as $message)	{		$messageStack->errors[] = $message;		$messageStack->size += 1;	}}

Now, I did have to do file merges on 4 files prior to install due to other mods and personal customizations....but I was very careful. Wondering if I made a merging error in another file that affects the init file? Below is a list of files I merged:

\includes\templates\custom_template\templates\tpl_contact_us_default.php
\includes\templates\custom_template\templates\tpl_product_reviews_write_default.php
\includes\modules\pages\contact_us\header_php.php
\includes\modules\pages\product_reviews_write\header_php.php

pickupman:

@ScriptJunkie
Try reuploading the file, as I don't see any syntax errors in the file that would cause that error. If that doesn't work, try removing the comment block (lines 2-5) and upload without the comment block.

Sorry I didn't get your PM. I didn't have notifications for that turned on somehow.

21 May 2012, 6:18 PM
#24
pickupman avatar

pickupman

New Zenner

Join Date:
Jun 2009
Posts:
83
Plugin Contributions:
2

Re: reCaptcha addon not showing in page

@ScriptJunkie
This line should be:

<?php
if (isset($_SESSION) AND is_numeric($_SESSION['admin_id']) AND is_object($reloadedStack) ){
    foreach ($reloadedStack->errors as $message)    {
        $messageStack->errors[] = $message;        
        $messageStack->size += 1;
    }
} 

Not sure if it was a copy and paste error but there needs to a space or line break between the php and if on that line.

21 May 2012, 6:57 PM
#25
scriptjunkie avatar

scriptjunkie

Totally Zenned

Join Date:
Jul 2008
Posts:
772
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

Sorry, I think that's just the way it was formatted by the forum's text editor when I selected the php tags. This is what it looks like in the file:

<?php
if (isset($_SESSION) AND is_numeric($_SESSION['admin_id']) AND is_object($reloadedStack) )
{
    foreach ($reloadedStack->errors as $message)
    {
        $messageStack->errors[] = $message;
        $messageStack->size += 1;
    }
}

The coding is the same as what you posted (expect for spacing), but to be safe, I copied what you posted and pasted it into the file, saved, and uploaded it to the server. Result is the same: a blank login page with the following error log:

PHP Parse error: syntax error, unexpected '{' in admin/includes/init_includes/init_reloadedstack.php on line 1

pickupman:

@ScriptJunkie
This line should be:

<?php if (isset($_SESSION) AND is_numeric($_SESSION['admin_id']) AND is_object($reloadedStack) ){ foreach ($reloadedStack->errors as $message) { $messageStack->errors[] = $message; $messageStack->size += 1; } } ``` > > Not sure if it was a copy and paste error but there needs to a space or line break between the php and if on that line.
21 May 2012, 7:10 PM
#26
pickupman avatar

pickupman

New Zenner

Join Date:
Jun 2009
Posts:
83
Plugin Contributions:
2

Re: reCaptcha addon not showing in page

@ScriptJunkie,
You have to have some sort of syntax error somewhere else. The syntax of the code you and both posted is correct. Try deleting the contents of the file, but leave the file in place and see if you have any other errors.

21 May 2012, 9:18 PM
#27
scriptjunkie avatar

scriptjunkie

Totally Zenned

Join Date:
Jul 2008
Posts:
772
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

The mystery deepens....After deleting the contents of the file and uploading the empty file to the server, I am able to access my admin login page with no errors generated in the cache file. Also, I am able to log in to my admin successfully - but there is no install button at the top of the page, nor is reCAPTCHA displayed in the config menu.

pickupman:

@ScriptJunkie,
You have to have some sort of syntax error somewhere else. The syntax of the code you and both posted is correct. Try deleting the contents of the file, but leave the file in place and see if you have any other errors.

21 May 2012, 9:27 PM
#28
scriptjunkie avatar

scriptjunkie

Totally Zenned

Join Date:
Jul 2008
Posts:
772
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

ScriptJunkie:

The mystery deepens....After deleting the contents of the file and uploading the empty file to the server, I am able to access my admin login page with no errors generated in the cache file. Also, I am able to log in to my admin successfully - but there is no install button at the top of the page, nor is reCAPTCHA displayed in the config menu.

Resolved!!

I noticed that before I emptied out the file, the file size was only 24 bytes. So I opened a new file in Notepad++, pasted in the code, saved it over the empty file and uploaded to the server. Logged in without incident, found the install button, and successfully installed. Will configure, test, and report results here.

I'm thinking something went wrong with decompression when I unzipped the fileset.

21 May 2012, 9:36 PM
#29
pickupman avatar

pickupman

New Zenner

Join Date:
Jun 2009
Posts:
83
Plugin Contributions:
2

Re: reCaptcha addon not showing in page

Whew. That explains the mystery. Let me know how it goes. Should be over the hump now.

21 May 2012, 11:35 PM
#30
scriptjunkie avatar

scriptjunkie

Totally Zenned

Join Date:
Jul 2008
Posts:
772
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

pickupman:

Whew. That explains the mystery. Let me know how it goes. Should be over the hump now.

Configured and tested - works beautifully :)

Thanks for a great mod and thank you so much for supporting it!!

24 May 2013, 12:20 AM
#31
jw1212 avatar

jw1212

New Zenner

Join Date:
May 2013
Location:
Tampa, FL
Posts:
27
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

I just installed module, but see on [install now] button in my zen cart admin console. Any idea where I went wrong?

24 May 2013, 1:25 AM
#32
jw1212 avatar

jw1212

New Zenner

Join Date:
May 2013
Location:
Tampa, FL
Posts:
27
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

JW1212:

see on [install now] button in my zen cart admin console. Any idea where I went wrong?

whoops, meant, I see "no" install button.

24 May 2013, 2:16 AM
#33
jw1212 avatar

jw1212

New Zenner

Join Date:
May 2013
Location:
Tampa, FL
Posts:
27
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

Well I got the install button but now I totally wrecked my contact us, log in, and my account page. http://www.desotosystemsflags.com/index.php

24 May 2013, 2:28 AM
#34
jw1212 avatar

jw1212

New Zenner

Join Date:
May 2013
Location:
Tampa, FL
Posts:
27
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

Also don't see ReCaptcha under configuration menu. I was able to configure it by hitting configure after installing it but after entering my keys and closing out I don't see it under config.

24 May 2013, 2:40 AM
#35
jw1212 avatar

jw1212

New Zenner

Join Date:
May 2013
Location:
Tampa, FL
Posts:
27
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

Sorry to be posting so much but I think I fixed the issue, now I see my contact form again however on contact page ENTRY_SECURITY_CHECK is being echoed to screen? and still don't see it under configuration.

24 May 2013, 10:26 AM
#36
jw1212 avatar

jw1212

New Zenner

Join Date:
May 2013
Location:
Tampa, FL
Posts:
27
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

JW1212:

Sorry to be posting so much but I think I fixed the issue, now I see my contact form again however on contact page ENTRY_SECURITY_CHECK is being echoed to screen? and still don't see it under configuration.

fixed, seems to be working now. Guess I just had to think out lout.

Although, I still don't see Recaptcha under config?

24 May 2013, 2:15 PM
#37
jw1212 avatar

jw1212

New Zenner

Join Date:
May 2013
Location:
Tampa, FL
Posts:
27
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

ok, now my brain is starting to hurt. I thought I had it all figured out, I've tested the ReCaptcha module and it works but now I get a blank page preventing me from logging in to my Zen Cart admin. I really miss my admin access :(

24 May 2013, 2:33 PM
#38
jw1212 avatar

jw1212

New Zenner

Join Date:
May 2013
Location:
Tampa, FL
Posts:
27
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

my last log entry:

[24-May-2013 08:31:00] PHP Warning: session_start() [<a href='function.session-start'>function.session-start</a>]: Cannot send session cookie - headers already sent by (output started at /home4/desotosy/public_html/_admin/includes/functions/extra_functions/recaptcha_functions.php:128) in /home4/desotosy/public_html/includes/functions/sessions.php on line 113
[24-May-2013 08:31:00] PHP Warning: session_start() [<a href='function.session-start'>function.session-start</a>]: Cannot send session cache limiter - headers already sent (output started at /home4/desotosy/public_html/_admin/includes/functions/extra_functions/recaptcha_functions.php:128) in /home4/desotosy/public_html/includes/functions/sessions.php on line 113
[24-May-2013 08:31:00] PHP Warning: Cannot modify header information - headers already sent by (output started at /home4/desotosy/public_html/_admin/includes/functions/extra_functions/recaptcha_functions.php:128) in /home4/desotosy/public_html/_admin/includes/init_includes/init_templates.php on line 28
[24-May-2013 08:31:00] PHP Warning: Cannot modify header information - headers already sent by (output started at /home4/desotosy/public_html/_admin/includes/functions/extra_functions/recaptcha_functions.php:128) in /home4/desotosy/public_html/_admin/includes/functions/general.php on line 21

24 May 2013, 2:51 PM
#39
jw1212 avatar

jw1212

New Zenner

Join Date:
May 2013
Location:
Tampa, FL
Posts:
27
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

ok so i removed "recaptcha_functions.php" and now I can log back in to my admin but now i'm not getting the contact form emails.

24 May 2013, 3:20 PM
#40
jw1212 avatar

jw1212

New Zenner

Join Date:
May 2013
Location:
Tampa, FL
Posts:
27
Plugin Contributions:
0

Re: reCaptcha addon not showing in page

All appears to be working at this moment. :smile: Thanks for the assistance...lol.

Module looks great still cant configure it through admin but at this point I'm not too worried about it.