[development] temporary access module

Larry Garfield larry at garfieldtech.com
Fri Feb 16 21:56:09 UTC 2007


Why not just use Actions.module to set the published flag on the node true and then send emails, then another action to set the published flag false after some period of time?  Not sure about the auto-account-creation, but you may want to look into logintobaggan.

--Larry Garfield

On Fri, 16 Feb 2007 15:47:55 -0500, "Alan Dixon" <alan.g.dixon at gmail.com> wrote:
> Hi drupalites:
> 
> I've been working on a little module i'm calling 'peek' and just
> wanted to check in on duplication of efforts, existing wisdom, etc.
> 
> The client wants to be able to create a page, and then fire off a
> bunch of emails to people who may or may not have accounts, allowing
> them to access the page temporarily.
> 
> So an administrator needs to be able to generate a semi-secret url
> (like the ones generated by the user module) that would give someone
> temporary access to a single node page.
> 
> After struggling with the node_access stuff for a while, i realised
> that i probably want to sidestep the usual permissions by providing
> access to the node page via a callback anyway.
> 
> So the url i'm generating looks like '/peek/<uid>/<timestamp>/<hd5 hash>'
> and my peek table keeps track of things like the corresponding nid,
> when it was generated, how long it's valid for, when it was first
> accessed, and how long it remains valid after first access. I've also
> got a helper function to generate new users for email address that
> don't already have a user. When the link is generated, the user gets
> authenticated to this uid. That way all subsequent activity is
> connected to their userid for tracking purposes.
> 
> Thoughts anyone?
> 
> --
> Alan Dixon, Web Developer
> http://alan.g.dixon.googlepages.com/



More information about the development mailing list