By Date: <-- -->
By Thread: <-- -->

lastuser



"Jason" <judgej (at) xaraya.com> wrote in message 
news:ejrrj7$tbi$1 (at) newton.xaraya.com...
> Out of curiosity, is there a reason why this information cannot be taken 
> directly from the roles tables, instead of via some module variable?

It could be. That actual modvar has been around for some time. It is also 
used in the installer and in the online block that jalal referred to.  I'm 
not sure of the original reason for needing it and when it was put in place, 
but they are the only places in our own monotone code repos that it is used, 
that i'm aware of. Perhaps other modules make user of it. I guess it's a 
quick way to get the 'last user' for whatever reason.

>If I wanted a block to display, say, the latest ten users to register, then 
>how would I go about doing that?

The registration date is recorded against the user in the roles table. So an 
sql query using date registered to grab the last 10. As jalal mentioned, 
there is no existing api in roles that provides parameters passed in to do 
that afaik. eg existing functions such as getall/getallactive return all 
users as implied by function name with no selection options for the specific 
use here

Jo



_______________________________________________
Xaraya_devel mailing list
Xaraya_devel (at) xaraya.com
http://xaraya.com/mailman/listinfo/xaraya_devel