Get users

Author Message

Nicolas Gommenginger

Friday 11 December 2009 7:00:41 am

Hi,

I'm righting a new cronjob script where I want to update some informations of the users of a specific group. So I would like to get all the users from this group and its sub-groups. I searched a lot but I can find the right way to do that...

Does someone have an idea ?

Thanks.

Nico

Nicolas Pastorino

Friday 11 December 2009 7:22:32 am

Hi Nicolas,

User objects, as well as User Group objects are normal content objects. This means you can fetch them wich the normal fetching methods, and then update the user information.

Check these examples : http://share.ez.no/forums/developer/how-to-do-a-fetch-with-php, or http://share.ez.no/forums/developer/how-to-update-an-attribute-of-an-object-with-php

Let us know how it goes,
Cheers,

--
Nicolas Pastorino
Director Community - eZ
Member of the Community Project Board

eZ Publish Community on twitter: http://twitter.com/ezcommunity

t : http://twitter.com/jeanvoye
G+ : http://plus.tl/jeanvoye

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:13:59
Script start
Timing: Jan 18 2025 05:13:59
Module start 'layout'
Timing: Jan 18 2025 05:13:59
Module start 'content'
Timing: Jan 18 2025 05:14:00
Module end 'content'
Timing: Jan 18 2025 05:14:00
Script end

Main resources:

Total runtime0.7767 sec
Peak memory usage4,096.0000 KB
Database Queries55

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0055 587.7891152.6094
Module start 'layout' 0.00550.0036 740.398439.3984
Module start 'content' 0.00910.7661 779.7969525.3359
Module end 'content' 0.77520.0015 1,305.13288.2031
Script end 0.7767  1,313.3359 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00360.4630160.0002
Check MTime0.00130.1727160.0001
Mysql Total
Database connection0.00130.166510.0013
Mysqli_queries0.732294.2763550.0133
Looping result0.00050.0602530.0000
Template Total0.745496.020.3727
Template load0.00250.323020.0013
Template processing0.742995.646420.3714
Template load and register function0.00010.013910.0001
states
state_id_array0.00100.132910.0010
state_identifier_array0.00120.156820.0006
Override
Cache load0.00200.2617170.0001
Sytem overhead
Fetch class attribute can translate value0.00060.073420.0003
Fetch class attribute name0.00090.122230.0003
XML
Image XML parsing0.00060.073520.0003
class_abstraction
Instantiating content class attribute0.00000.001430.0000
General
dbfile0.00080.1006160.0000
String conversion0.00000.001240.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
2content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
4content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.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/link.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/link.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 11
 Number of unique templates used: 7

Time used to render debug report: 0.0002 secs