but then you may miss out on tracking. And if you use database to store it anyways, then u can use the db in the first place also :-)

Regards,
Bhaskar

Paul Joseph wrote:

Yes, these are much better approaches expecially (imo)
the xml approach as it has fewer "moving parts" - no
quartz and also, it doesn't have the overhead of
talking to a db.

thx
Paul
--- Derek Hohls <[EMAIL PROTECTED]> wrote:



Alternatively you could be using flow for this and
reading the variable from an xml file - along with any other useful info such as user name etc - and also checking the time using javascript in flow and testing if the last login was before/after midnight and then resetting as needed.


AFAIK (and a little knowledge is a dangerous thing!)
the so-called "global variable" in the Cocoon
sitemap
is more like a "global constant"...  but I'd like to
hear
differently.

[There was a previous thread on dynamically creating
subsitemaps... I thibnk one of the developers said
it could be done but was somewhat dubious about its
lack of merits and possible dangers... but, hey,
you're
a programmer and current "Master of the Universe"!!]




[EMAIL PROTECTED] 2004/08/20 09:19:20 AM >>>


Alternatively, you could log every logon to the
system with a database

timestamp and do checking there.

It's just a matter of what is more familiar to you,
there are various ways of achieving this.


Paul Joseph wrote:


Hi,

I am wondering how best to do this in Cocoon:

When a user logs in, the user has to check if they


are


the first person to login for the day and if so,


do


some tasks.

To do this, I though of setting a global variable


say


FIRST_LOGIN=true at midnight every night - using


the


Quartz scheduler.

Then when a user logged in, as part of the
authentication logic, I would have them check this
variable and do the action if it was true. Of


course,


after doing the action, they would set this


variable


to false.

Any pointers as to how this can best be done would


be


appreciated. I am unable to implement this


approach


at present as I do not know how to set a global
variable whose value can be altered dynamcially.

thx
Paul





---------------------------------------------------------------------


To unsubscribe, e-mail:
[EMAIL PROTECTED] For additional commands, e-mail:
[EMAIL PROTECTED]



-- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. MailScanner thanks transtec Computers for their support.





---------------------------------------------------------------------


To unsubscribe, e-mail:
[EMAIL PROTECTED]
For additional commands, e-mail:
[EMAIL PROTECTED]






---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to