user can choose a usergroup on signup?

Author Message

Daniel Lausch

Tuesday 17 October 2006 6:30:17 am

hi guys.

how is this possible?

im a eznoob :-(

if a user signup to my sitee he have to be able to choose a usergroup like premium/default

greetz

Lausch

Claudia Kosny

Thursday 19 October 2006 10:16:31 am

Hi Daniel

Unfortunately I don't think this is easy to do as you would have to write this functionality yourself. So you need to have a good knowledge of PHP and the will to plow through some EZ code to get an understanding for the inner workings.

My idea (thoroughly untested) would be to use the customedithandler
http://serwatka.net/index.php/en/blog/ez_publish_3_8_new_custom_edit_handler
to fetch the node of the published user object and then move this node to the respective user group. Moving a node using PHP is pretty simple, you just use something like $currentNode->move($newParentNodeId);

There might be one big problem: I don't know how the user and it's user group are connected. If it is just by placement, similar to an article and it's parent folder, the above idea should work ok. If there is another connection I don't know what it is and how to change it depending on some user input.

Good luck

Claudia

Paul Borgermans

Thursday 19 October 2006 10:33:24 am

Hi

There might be one big problem: I don't know how the user and it's user group are connected.
 If it is just by placement, similar to an article and it's parent folder, the above idea should 
work ok. If there is another connection I don't know what it is and how to change it depending
on some user input.

Indeed, users are just content objects and the node placements defines to which group they belong. It is just the user/group/role related functions which take this into account

hth

Paul

eZ Publish, eZ Find, Solr expert consulting and training
http://twitter.com/paulborgermans

Claudia Kosny

Thursday 19 October 2006 11:08:32 am

Thanks Paul, that is good to know.

Claudia

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 19 2025 09:50:14
Script start
Timing: Jan 19 2025 09:50:14
Module start 'layout'
Timing: Jan 19 2025 09:50:14
Module start 'content'
Timing: Jan 19 2025 09:50:14
Module end 'content'
Timing: Jan 19 2025 09:50:14
Script end

Main resources:

Total runtime0.5653 sec
Peak memory usage4,096.0000 KB
Database Queries62

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0071 589.1719152.6250
Module start 'layout' 0.00710.0027 741.796939.4453
Module start 'content' 0.00980.5541 781.2422577.3984
Module end 'content' 0.56390.0014 1,358.640612.1563
Script end 0.5653  1,370.7969 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00350.6173160.0002
Check MTime0.00130.2322160.0001
Mysql Total
Database connection0.00100.176910.0010
Mysqli_queries0.511490.4636620.0082
Looping result0.00060.1004600.0000
Template Total0.530993.920.2654
Template load0.00230.408820.0012
Template processing0.528593.489820.2643
Template load and register function0.00010.025810.0001
states
state_id_array0.00110.199510.0011
state_identifier_array0.00100.178720.0005
Override
Cache load0.00200.3545280.0001
Sytem overhead
Fetch class attribute can translate value0.00060.106830.0002
Fetch class attribute name0.00090.156250.0002
XML
Image XML parsing0.00080.141030.0003
class_abstraction
Instantiating content class attribute0.00000.001650.0000
General
dbfile0.00390.6930170.0002
String conversion0.00000.004240.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
4content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
6content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 15
 Number of unique templates used: 7

Time used to render debug report: 0.0001 secs