Registration page fails to load

Hello!
Recently the registration page on my installation of OJS stopped working. I see following lines in the apache log when I try to load it:

PHP Warning:  Declaration of RegistrationHandler::validate($request) should be compatible with PKPHandler::validate($requiredContexts = NULL, $request = NULL) in /var/www/ojs/lib/pkp/pages/user/RegistrationHandler.inc.php on line 19
PHP Warning:  Declaration of RegistrationForm::validate() should be compatible with Form::validate($callHooks = true) in /var/www/ojs/lib/pkp/classes/user/form/RegistrationForm.inc.php on line 21
PHP Notice:  Undefined property: Smarty_Internal_Undefined::$objMap in /var/www/ojs/lib/pkp/lib/vendor/smarty/smarty/libs/sysplugins/smarty_internal_extension_handler.php on line 132
PHP Fatal error:  Uncaught  --> Smarty: undefined extension class 'Smarty_Internal_Method_Register_Outputfilter' <-- \n  thrown in /var/www/ojs/lib/pkp/lib/vendor/smarty/smarty/libs/sysplugins/smarty_internal_undefined.php on line 62

I’ve already encountered one problem that turned out to be caused by some broken DB records. Maybe this is something similar?

Hi @Taomach

What OJS version are you using? It seems that you have conflicts with Smarty version. It can be possible, for example, if you are using the OJS code from the master branch and a theme that is not updated yet.

Yes, I do use the latest git snapshot of OJS. I use the default theme from the same snapshot, though.

Quite possible that default theme isn’t updated yet. You can try 3.2 branch of Health Sciences theme, I’ve updated it recently to Smarty v.3

But my suggestion is to stick with the recent stable release of OJS.

Not an option, unfortunately. We need the localized names feature that only the git version has. I will give the Health Sciences theme a shot, thanks for the suggestion.

UPD:
Welp, the Health Sciences theme didn’t work either. I pulled the 3.2 branch and got the exact same error on trying to open the registration page.

Did you cleare the cache? But also probably recent commits included changes in registration process. Will take a look.

Hi @Taomach,

FYI, we’re going to be merging some very large features (including metadata versioning) in the near future that are going to break aspects of the master branch – you’re welcome to work with pre-release code, but beware of using it in production before it’s ready. If you’re concerned about stability in the next few months it might be best to work with a snapshot, but beware that upgrading from there to the final 3.2 release will be an unsupported process.

Regards,
Alec Smecher
Public Knowledge Project Team

I did now, it didn’t help.

Thank you.

Hi @asmecher,
Thanks for the heads up. I think, I’ll stay on the snapshot for the time being, and deal with the upgrade when the time comes to it.

A couple of years later but maybe someone else can benefit from this.
I had the exact same problem @Taomach describes.

This was my error log:

[Wed Dec 30 20:16:48 2020] PHP Warning:  Declaration of AddThisPlugin::register($category, $path) should be compatible with LazyLoadPlugin::register($category, $path, $mainContextId = NULL) in /Users/gabe/Code/local-evidencia-ojs-stable-3_1_2/plugins/generic/addThis/AddThisPlugin.inc.php on line 168
[Wed Dec 30 20:16:48 2020] PHP Warning:  Declaration of CustomBlockPlugin::getBlockContext() should be compatible with BlockPlugin::getBlockContext($contextId = NULL) in /Users/gabe/Code/local-evidencia-ojs-stable-3_1_2/plugins/generic/customBlockManager/CustomBlockPlugin.inc.php on line 134
[Wed Dec 30 20:16:48 2020] PHP Warning:  Declaration of RegistrationHandler::validate($request) should be compatible with PKPHandler::validate($requiredContexts = NULL, $request = NULL) in /Users/gabe/Code/local-evidencia-ojs-stable-3_1_2/lib/pkp/pages/user/RegistrationHandler.inc.php on line 19
[Wed Dec 30 20:16:48 2020] PHP Warning:  Declaration of RegistrationForm::validate() should be compatible with Form::validate($callHooks = true) in /Users/gabe/Code/local-evidencia-ojs-stable-3_1_2/lib/pkp/classes/user/form/RegistrationForm.inc.php on line 21
[Wed Dec 30 20:16:48 2020] PHP Warning:  call_user_func() expects parameter 1 to be a valid callback, class 'OldGreggThemePlugin' does not have a method 'htmlDisplay' in /Users/gabe/Code/local-evidencia-ojs-stable-3_1_2/lib/pkp/classes/plugins/HookRegistry.inc.php on line 107
[Wed Dec 30 20:16:48 2020] PHP Notice:  Undefined property: Smarty_Internal_Undefined::$objMap in /Users/gabe/Code/local-evidencia-ojs-stable-3_1_2/lib/pkp/lib/vendor/smarty/smarty/libs/sysplugins/smarty_internal_extension_handler.php on line 132
[Wed Dec 30 20:16:48 2020] PHP Fatal error:  Uncaught  --> Smarty: undefined extension class 'Smarty_Internal_Method_Register_Outputfilter' <--
  thrown in /Users/gabe/Code/local-evidencia-ojs-stable-3_1_2/lib/pkp/lib/vendor/smarty/smarty/libs/sysplugins/smarty_internal_undefined.php on line 62
[Wed Dec 30 20:16:48 2020] [::1]:56236 [500]: /index.php/Evidencia/user/register - Uncaught  --> Smarty: undefined extension class 'Smarty_Internal_Method_Register_Outputfilter' <--
  thrown in /Users/gabe/Code/local-evidencia-ojs-stable-3_1_2/lib/pkp/lib/vendor/smarty/smarty/libs/sysplugins/smarty_internal_undefined.php on line 62

This post enlightened me about a conflict with the ORCID plugin. Disabling or updating ORCID plugin to my ojs version (3.1.2) corrected the situation.