[Zope-CMF] Automatic ID generation -- > Title Got it!
Ivan Cornell
icornell@yahoo.com
Tue, 24 Apr 2001 10:53:39 +0100 (BST)
> > <dtml-call "REQUEST.set('ts', ZopeTime().strftime('%Y%m%d%H%M%S'))">
> > <dtml-with ts>
> > <tr valign="top">
> > <td> <br> </td>
> > <td colspan="2"> <strong> Folder Name or Resource Title: </strong>
> > <input type="text" name="id" value="<dtml-var ts>" size="50">
> > <input type="submit" value="Add"> </td>
> > </tr>
> > </dtml-with>
> <input type="hidden" name="id" value="<dtml-var ts>" size="50">
>
If you don't use ts anywhere else, you could simplify that whole lot to
just:
<input type="hidden" name="id" value="<dtml-var
"ZopeTime().strftime('%Y%m%d%H%M%S'))">"
or even:
<input type="hidden" name="id" value="<dtml-var ZopeTime
fmt="%Y%m%d%H%M%S">"
Ivan
____________________________________________________________
Do You Yahoo!?
Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk
or your free @yahoo.ie address at http://mail.yahoo.ie