[Zope] bobobase_mod_time of other objects

Timothy Wilson wilson@visi.com
Thu, 30 Mar 2000 16:20:21 -0600 (CST)


On Thu, 30 Mar 2000, Andrew Diller wrote:

> Hello- if I want to use bobobase_modification_time to tell me when another object has been updated,
> how would I format it?
> 
> For instance, in a index_html DTML document I want to list the last update of other objects in the
> same folder (other DTML documents and methods). I can't get bobobase to reference _other_ objects.
> 
> Is this possible?

In a word, yes. :-)

Here's how I do it on my site. This line tells me when a particular object
(a file object as it turns out) was last updated:

<dtml-var "_['Bookmark.htm'].bobobase_modification_time()" fmt=Day>,
<dtml-var "_['Bookmark.htm'].bobobase_modification_time()" fmt=pCommon>

The output looks like (for example):
Tuesday, Mar. 7, 2000 11:35am

The extra '_' business in my dtml-var tag is necessary because my file
object has a '.' in its name. I believe that

<dtml-var "spamobject.bobobase_modification_time()" fmt=Day>

should do it if you don't have a '.'

HTH,
Tim

--
Tim Wilson      | Visit Sibley online:         | Check out:
Henry Sibley HS | http://www.isd197.k12.mn.us/ | http://www.zope.org/
W. St. Paul, MN |                              | http://slashdot.org/
wilson@visi.com |   <dtml-var pithy_quote>     | http://linux.com/