some object properties

Properties Generated By getRuntimeVars()

Your Berylium object has been loaded from the database, and a slew of URLs has been generated for it for use within various namespaces, but it still may not be ready for rendering.

Who created it? Is the date formatted correctly? Does it have an icon, a copyright? All of these questions are answered when you call the getRuntimeVars() method in your contexts.

Note: getRuntimeVars() properties cache. If you need to regenerate them for some reason, call the method with a single argument, like $this->getRuntimeVars(1);

Time Formatting

First, created and updated are formatted accoring to the PHP date() format "F j, Y \a\\t g:ia", which makes them look like January 5, 2004 at 1:45pm.

$this->timeFormat( $format ), which can also be called later with a custom format, generates some other time-related properties. Here's the full set:
  • created = formatted creation date
  • createdSql = MySQL datestamp
  • createdStamp = Unix timestamp (seconds since 1970)
  • updated = formatted modification date
  • updatedSql = MySQL datestamp
  • updatedStamp = Unix timestamp
  • timeFormatted = PHP date() format string currently in use

Backdating Support

If $this->p_originaldate is set, then it means that the author wishes to "backdate" the object, to make it appear to have been created before the object was created in Berylium. In this case, originaldate is set, formatted using PHP date() format "l, F j, Y", which is like Sunday, January 5, 2004.

Also, dateTag is set to be the same as originaldate.

If $this->p_originaldate is NOT set, then dateTag is set to be the same (formatted) date as created.
  • originaldate = formatted backdate or ""
  • dateTag = either originaldate or created, depending on whether the object should be backdated

Publishing Status

A number of properties are generated regarding the publishing status (public, status and rank) of the object:
  • lightrank = rank used for the bulb icon (50, 100, 500, or 1000)
  • logstatus = public-status-rank string
  • glow = public-status-lightrank string
  • iconpvt - "-pvt" if object is private, for appending to the bicon name

Object Icon

Custom object icons aren't supported (at the moment) in Berylium, but every object has an imageid property that can be used to refer to the Berylium image that should be used as its icon.
  • iconTag - full HTML <img> tag of object's icon

About The Author

Any Berylium object can have two different types of author properties associated with it: the sitemember who created the object (the owner), and the data optionally filled into the author field. Since the owner's sitemember record is an object in its own right, the whole thing is pulled out of the database and loaded into authorObj for you to access in context.
  • authorObj = sitemember object of owner (with URLs)
  • authorName = hyperlinked owner name
  • authorPlain = plain text owner name
  • authorTag = author data if set, otherwise same as authorName
Note that the author field may contain parsed BML with links and icons (or RSS feeds, heaven forbid).

Safe Title

Since the title field may contain parsed BML, it isn't always suitable for the title attributes of HTML tags, or the subject line of an email, so:
  • safetitle = plain text title

Source and Copyright

The following HTML renderings are generated if the optional fields source and copyright are set:
  • sourceTag = HTML formated object source statement
  • copyrightTag = HTML formatted rights information

By Chris Snyder on June 25, 2003 at 7:55pm

jump to top