Multiple registration form

Author Message

Roberto Donato

Friday 27 November 2009 6:16:36 am

Hello,
as written in the subject I need to create a registration form for multiple user groups. In other posts I read that I need to create a siteaccess for each registration form. But if I have 5-6 groups, I have to create 5-6 siteaccess? Can I create a select inside the form to the choice of the group to associate the user?

Romain Petit

Saturday 28 November 2009 4:49:20 am

Hi Roberto,

The register function does not meet your needs,

You may have to copy it into an extension, and then modify the part of register.php where it fetches the UserSettings/DefaultUserPlacement setting, and replace it with some POST variable ( with precise checks ).
And then just give access to your new module for anonymous users.

Luc Chase

Monday 30 November 2009 3:58:05 pm

Using workflow to add extra user-group locations to the new user may also help you... http://share.ez.no/forums/developer/workflow-removesubtrees-addlocation

The Web Application Service Provider

Roberto Donato

Wednesday 02 December 2009 6:13:19 am

"

Hi Roberto,

The register function does not meet your needs,

You may have to copy it into an extension, and then modify the part of register.php where it fetches theUserSettings/DefaultUserPlacement setting, and replace it with some POST variable ( with precise checks ).
And then just give access to your new module for anonymous users.

"

Hello everyone and thanks for the answers.
Romain I created an extension like you suggested, but I did not know where to edit register.php to set the value of the user group.

Roberto

Matthieu Sévère

Wednesday 02 December 2009 6:44:02 am

Hello !

I just implement a registration system with multiple location.

I created a custom workflow event that I trigger after publish. In this event I retrieve a form parameter which determine the type of user and then I move the newly created user depending on this parameter.

--
eZ certified developer: http://ez.no/certification/verify/346216

Roberto Donato

Wednesday 02 December 2009 7:35:30 am

"

Hello !

I just implement a registration system with multiple location.

I created a custom workflow event that I trigger after publish. In this event I retrieve a form parameter which determine the type of user and then I move the newly created user depending on this parameter.

"

I've never worked on the trigger in eZ publish, you could tell me how?

Matthieu Sévère

Wednesday 02 December 2009 8:09:09 am

First you have to create a custom workflow event (see some custom workflow on projects.ez.no to see how to do).

Then, you go to setup / workflow and add your workflow event for the class you want

After that you go to setup / trigger and select your workflow to trigger after/publish.

You'll have the php code of your workflow event that is executed after every publish :-)

--
eZ certified developer: http://ez.no/certification/verify/346216

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 05:01:14
Script start
Timing: Jan 18 2025 05:01:14
Module start 'layout'
Timing: Jan 18 2025 05:01:14
Module start 'content'
Timing: Jan 18 2025 05:01:16
Module end 'content'
Timing: Jan 18 2025 05:01:16
Script end

Main resources:

Total runtime1.4736 sec
Peak memory usage4,096.0000 KB
Database Queries73

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0073 589.0313152.6250
Module start 'layout' 0.00730.0051 741.656339.4453
Module start 'content' 0.01241.4597 781.1016653.6094
Module end 'content' 1.47210.0014 1,434.710916.1641
Script end 1.4735  1,450.8750 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00320.2178160.0002
Check MTime0.00130.0908160.0001
Mysql Total
Database connection0.00130.090610.0013
Mysqli_queries1.410595.7220730.0193
Looping result0.00080.0547710.0000
Template Total1.422096.520.7110
Template load0.00200.133120.0010
Template processing1.420096.366320.7100
Template load and register function0.00020.012910.0002
states
state_id_array0.00330.224210.0033
state_identifier_array0.00340.228820.0017
Override
Cache load0.00170.1158380.0000
Sytem overhead
Fetch class attribute can translate value0.00110.075440.0003
Fetch class attribute name0.00130.091180.0002
XML
Image XML parsing0.00110.072040.0003
class_abstraction
Instantiating content class attribute0.00000.001190.0000
General
dbfile0.00080.0565160.0001
String conversion0.00000.000740.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
7content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
4content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
11content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
2content/datatype/view/ezxmltags/quote.tpldatatype/ezxmltext/quote.tplextension/ezwebin/design/ezwebin/override/templates/datatype/ezxmltext/quote.tplEdit templateOverride template
2content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 28
 Number of unique templates used: 7

Time used to render debug report: 0.0001 secs