Advertisement:

Register link produces Template Parse Error

Aloittaja milesenglish, tammikuu 19, 2009, 02:42:38 IP

« edellinen - seuraava »

milesenglish

Hi,

Our board has been getting hit with a lot of spam bots.  A while back I tried installing reCaptcha but it didn't install correctly and required some template edits which I didn't have time to do.  So the problem persisted.  Today I tried installing Are you Human and Anti Bot Registration Puzzle.  Now when I click on the registration link I get a Template Parse Error! page.  I tried uninstalling those packages (all three) to no avail.

Here's an error for my log:
Apply Filter: Only show the error messages of this member  Guest       Today at 01:50:43 PM
Apply Filter: Only show the error messages of this IP address 65.175.146.186      Apply Filter: Only show the error messages of this session d24f9808e3ad283027f57df0727aa1ae
Apply Filter: Only show the error messages of this URL http://nedoc.org/forums/index.php?action=register
Apply Filter: Only show the errors with the same message
8: Undefined index: are_you_human_yes
File: /home/nedocorg/public_html/forums/Themes/default/Register.template.php (before sub template - eval?)
Line: 201

Since I've removed the packages I still get the Parse page but I don't have any new entries into my error log.

Any help would be greatly appreciated!

greyknight17

Attach your /Themes/default/Register.template.php file here.


greyknight17

Can you go to Admin > Packages and confirm that the Anti-Bot mod was uninstalled? It should give you an option to install it now, so that would be a good indication that it was previously removed. If that checks out then try using the attached file to see if it fixes the problem.

milesenglish

That worked!  Thanks so much.  Now, can I go back and attempt to use one of those anti bot packages or no?

greyknight17

No problem. Glad it worked out.

Yes, you may install those Anti-bot mods if you like. Just make sure to do any edits for your custom theme templates if they apply. Most likely they will not apply, so you should not need to make any manual changes. To find out, go to one of the mod's page and right underneath the download links are the manual installation link. Choose your SMF version and submit it. See if any of your custom theme template files are mentioned. If not, just install it via Package Manager and it should work with both your default and custom themes.

milesenglish

Crap,  I just found out that I still have a problem.  At first I couldn't click on the Register link.  Uploading the new php file made the Register link work but if you actually go through and attempt to actually register a new member I get a screen that reads "An Error Has Occurred!"

Now what?  :-[

milesenglish

I checked our site's error log and here's the message we get when people try to register:
Guest    Today at 09:37:08 AM
81.24.208.9      fc1c18e15ade1f69c0b38d9c938f115d
http://nedoc.org/forums/index.php?action=register
8: Undefined index: puzzle_3
File: /home/nedocorg/public_html/forums/Sources/Register.php(117) : runtime-created function
Line: 15


If anyone has a minute to help out with this I'd appreciate it.  I hate to think that potential members are just giving up...

Kermit

Apparently the related language string is missing

Check out your Modifications.english.php

$txt['puzzle_3'] = 'THREE';

and if you don't have such a line,then add it before

?>
My Mods
Please don't PM/mail me for support,unless i invite you
Formerly known as Duncan85
Lainaa
"Two things are infinite: the universe and human stupidity; and I'm not sure about the the universe."

A. Einstein

milesenglish

#9
I added that line to forums/themes/pdx-dk-09i/languages/modifications.english.php at the end just before ?> and tried to register a new user.  I got the same error screen after submitting.  Our error log generated this:

Guest    Today at 12:29:31 PM
64.65.198.16      4f3e878b08a477c4b4fd049ced3134fd
http://nedoc.org/forums/index.php?action=register2
8: Undefined index: puzzle_incomplete
File: /home/nedocorg/public_html/forums/Sources/Errors.php
Line: 342

Did I enter it incorrectly or in the wrong place perhaps?

Kermit

As i see all language strings related to puzzle mod are missing on your forum


also

in Modifications.english.php

Koodi (find) [Valitse]

?>



Koodi (add before) [Valitse]


$txt['puzzle_colors'] = 'Which word is the same as its color';
$txt['puzzle_math'] = 'What is the sum of (as a number)';
$txt['puzzle_shapes'] = 'How many %s does a %s have?';
$txt['puzzle_shapes2'] = 'How many %s does an %s have?';
$txt['puzzle_sides'] = 'sides';
$txt['puzzle_corners'] = 'corners';
$txt['puzzle_incomplete'] = 'You did not complete the anti-bot puzzle. Please try again.';
$txt['puzzle_incorrect'] = 'You incorrectly answered the anti-bot puzzle. Please try again.';
$txt['puzzle_antibot'] = 'Anti-bot measure';
$txt['puzzle_red'] = 'Red';
$txt['puzzle_orange'] = 'Orange';
$txt['puzzle_yellow'] = 'Yellow';
$txt['puzzle_green'] = 'Green';
$txt['puzzle_blue'] = 'Blue';
$txt['puzzle_purple'] = 'Purple';
$txt['puzzle_pink'] = 'Pink';
$txt['puzzle_black'] = 'Black';
$txt['puzzle_grey'] = 'Grey';
$txt['puzzle_triange'] = 'Triangle';
$txt['puzzle_square'] = 'Square';
$txt['puzzle_rectangle'] = 'Rectangle';
$txt['puzzle_pentagon'] = 'Pentagon';
$txt['puzzle_hexagon'] = 'Hexagon';
$txt['puzzle_heptagon'] = 'Heptagon';
$txt['puzzle_octagon'] = 'Octagon';
$txt['puzzle_1'] = 'ONE';
$txt['puzzle_2'] = 'TWO';
$txt['puzzle_3'] = 'THREE';
$txt['puzzle_4'] = 'FOUR';
$txt['puzzle_5'] = 'FIVE';
$txt['puzzle_6'] = 'SIX';
$txt['puzzle_7'] = 'SEVEN';
$txt['puzzle_8'] = 'EIGHT';
$txt['puzzle_9'] = 'NINE';
$txt['puzzle_10'] = 'TEN';
$txt['puzzle_11'] = 'ELEVEN';
$txt['puzzle_12'] = 'TWELVE';
$txt['puzzle_13'] = 'THIRTEEN';
$txt['puzzle_14'] = 'FOURTEEN';
$txt['puzzle_15'] = 'FIFTEEN';
$txt['puzzle_16'] = 'SIXTEEN';
$txt['puzzle_17'] = 'SEVENTEEN';
$txt['puzzle_18'] = 'EIGHTEEN';
$txt['puzzle_19'] = 'NINETEEN';

My Mods
Please don't PM/mail me for support,unless i invite you
Formerly known as Duncan85
Lainaa
"Two things are infinite: the universe and human stupidity; and I'm not sure about the the universe."

A. Einstein

milesenglish

OK, now I get an error that states:
You did not complete the anti-bot puzzle. Please try again.

I'm certain I entered the letters of the puzzle correctly (I listened to them to double check).

Kermit

I can't not say what is exactly wrong with your codes,but sth. went wrong with your Anti-Bot Registration Puzzles mod

http://custom.simplemachines.org/mods/index.php?action=parse;mod=1078;attach=51788;smf_version=1.1.7

I would suggest you to check your codes manually via installation instuctions from above
My Mods
Please don't PM/mail me for support,unless i invite you
Formerly known as Duncan85
Lainaa
"Two things are infinite: the universe and human stupidity; and I'm not sure about the the universe."

A. Einstein

milesenglish

Good advice - I was missing some code in my register.template.php file.  I added it and now it works.

Thanks for all your help Duncan!

alios

#14
i tryied to install recaptcha, but now i-m getting the error as above

Template Parse Error!
There was a problem loading the /Themes/default/Register.template.php template or language file. Please check the syntax and try again - remember, single quotes (') often have to be escaped with a slash (\). To see more specific error information from PHP, try accessing the file directly.


also in the error log i get:

8: Undefined variable: php_errormsg
File: /home/comunitate/www/forum/Sources/Load.php
Line: 1833

what to do ? i-ve tryied everything

i don-t want to reinstal a whole forum for this template :(

Advertisement: