Share » Forums » Install & configuration » Two different users that should...

Two different users that should register in the site

Two different users that should register in the site

Wednesday 28 April 2010 7:49:01 pm - 2 replies

Author Message

Andreas Adelsberger

Wednesday 28 April 2010 11:15:51 pm

You can use a this extension:

http://ez.no/developer/contribs/workflow/automated_user_placment

Create your own registration form and hide the selection. To select the right usergroup you can pass a view parameter to your form like user/register/(type)/needmember

---------------------------------------
Styleflasher New Media OG
Websites. Games/Multimedia.

Abdelkader RHOUATI

Thursday 29 April 2010 2:04:50 am

HI,

This feature does not exist by default on ez, so I think the most simple and clean, will:

1 - Override the user module (override only the register view, with create a module and a view with the same name, ie user and register, in an extension). also adjusts the view definition so that it takes as a parameter the desired location.

2 - Override the template user/register.tpl, to be able to sent in hidden input the location of new user.

3 - On line 118, of the file view register (register.php); you replace:

$DefaultUserPlacement = (int) $ ini-> variable ("UserSettings", "DefaultUserPlacement");

by

// assume that the location is sent by  post from the registration form

$DefaultUserPlacement = (int) $ http->getVariable('location');

Regrads.

Abdelkader RHOUATI

Blog (french) : http://arhouati.com
----
Extension arh_jdebug : EzDebug using jquery

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu