Self Registration broken after upgrade "not used anymore"

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
User avatar
paulbaker
Dev Team Member
Dev Team Member
Posts: 1465
Joined: Sat Apr 18, 2009 10:09 pm
Contact:

Self Registration broken after upgrade "not used anymore"

Post by paulbaker »

So, I had a simple site with Self Registration (Selfreg) set up. Users would fill in a registration form, they got added to a "Pre approved" group. Site owner would get an email informing them. Site owner would then enter back end and (if new user is approved) change them from "Pre approved" group to "Website users" group and inform new user by email. The new user could then login to FEU and view site.

It worked well. Then, like a good boy, I upgraded my modules: SelfRegistration to 1.9.

I tested the registration process and when I register I just see a broken page with no HEAD code and a BODY from one of the Templates with content simply:
not used anymore
I was expecting the content in Users & Groups > Self Registration module > Final Message Template to be shown (as it was before my upgrade).

A lot of head scratching followed, I combed through the database and all the website files and eventually found, in modules/SelfRegistration/action.post_createuser.php:

Code: Select all

if( !isset($gCms) ) exit;
die('not used anymore');

$params = selfreg_utils::clean_params($params);

if( isset($params['username']) ) $smarty->assign('username',$params['username']);
if( isset($params['email']) ) $smarty->assign('email',$params['email']);

echo $this->ProcessTemplateFromDatabase('selfreg_finalmessage_template');
The 2nd line is the important bit. This was not in the previous version.

I see from the release notes of 1.9 SelfReg on http://dev.cmsmadesimple.org/project/files/15 that:
This module has undergone serious changes in this series. There may be compatibility issues and you WILL have to reset many of the templates you use and re-test.
My code in the registration Page remains unchanged:

Code: Select all

{cms_module module=SelfRegistration group="Pre approved"}
I reset (by clicking "Set to Defaults" button and pressing Submit) the 2 "Registration Template 1" templates and the "Final Message Template". But the behaviour is still the same. I don't think any of the other SelfReg templates are used in my application.

How do I get back the original functionality as described in my paragraph 1 above?

Thank you ;D

----------------------------------------------
Cms Version: 1.11.13
Installed Modules:
CMSMailer: 5.2.2
CMSPrinting: 1.0.5
FileManager: 1.4.5
MenuManager: 1.8.6
MicroTiny: 1.2.9
ModuleManager: 1.5.8
News: 2.15
Search: 1.7.12
ThemeManager: 1.1.8
CGExtensions: 1.46.4
FrontEndUsers: 1.28
SelfRegistration: 1.9
SEOTools2: 1.2.1
Notifications: 1.1
CGSimpleSmarty: 1.8
Archiver: 0.2.6

Config Information:
php_memory_limit:
process_whole_template:
max_upload_size: 64000000
url_rewriting: mod_rewrite
page_extension:
query_var: page
image_manipulation_prog: GD
auto_alias_content: true
locale:
default_encoding: utf-8
admin_encoding: utf-8
set_names: true

Php Information:
phpversion: 5.5.20
md5_function: On (True)
gd_version: 2
tempnam_function: On (True)
magic_quotes_runtime: Off (False)
E_STRICT: 0
E_DEPRECATED: 0
memory_limit: 128M
max_execution_time: 30
output_buffering: 4096
safe_mode: Off (False)
file_uploads: On (True)
post_max_size: 64M
upload_max_filesize: 64M
session_save_path: /tmp (1777)
session_use_cookies: On (True)
xml_function: On (True)
xmlreader_class: On (True)

Server Information:
Server Api: cgi-fcgi
Server Db Type: MySQL (mysql)
Server Db Version: 5.5.35
Server Db Grants: Could not find a suitable "GRANT ALL" permission. This may mean you could have problems installing or removing modules. Or even adding and deleting items, including pages
Server Time Diff: No filesystem time difference found

----------------------------------------------
To copy System Information to the forum:
https://docs.cmsmadesimple.org/troubles ... nformation

CMS Made Simple Geekmoots attended:
Nottingham, UK 2012 | Ghent, Belgium 2015 | Leicester, UK 2016
calguy1000
Support Guru
Support Guru
Posts: 8169
Joined: Tue Oct 19, 2004 6:44 pm

Re: Self Registration broken after upgrade "not used anymore

Post by calguy1000 »

it was an oversight on my part paul.
Deleting that one line should restore the functionality.
I will have a new version out sometime today (but it has other functionality as well).

Thank you for your very well described posting allowing me to easily identify identify the issue.
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
User avatar
paulbaker
Dev Team Member
Dev Team Member
Posts: 1465
Joined: Sat Apr 18, 2009 10:09 pm
Contact:

Re: Self Registration broken after upgrade "not used anymore

Post by paulbaker »

calguy1000 wrote:Thank you for your very well described posting allowing me to easily identify identify the issue.
No worries! Thank you for replying within less than 2 hours with a solution! I was able to make the change straight away and get the site running again.

Thanks Calguy. 8)
To copy System Information to the forum:
https://docs.cmsmadesimple.org/troubles ... nformation

CMS Made Simple Geekmoots attended:
Nottingham, UK 2012 | Ghent, Belgium 2015 | Leicester, UK 2016
Post Reply

Return to “Modules/Add-Ons”