Fog Creek Software
Discussion Board




Knowledge Base
Documentation
Terry's Tips
Darren's Tips

Just what are "placeholder?"

OK, can anyone explain to me the difference between "placeholders" and "built-in variables" in Cdesk?

rick

Rick Chapman
Thursday, March 18, 2004

In what context? Could you give us an example of where you encountered the term 'placeholder'? Was it in the help file, or somewhere online?

Darren Collins
Thursday, March 18, 2004

It does seem like CityDesk uses three similar names for three similar but distinct functions.  I think the distinction is as follows:

Placeholders are the cityscript values that are used in templates or loops and hold the defined parts of an article, like {$.headline$} or {$x.body$}.  At publish time, they are replaced by the corresponding field from the current article.

Variables are cityscript values that are replaced by whatever you've defined in the variables list.  Stuff like {$.sitename$} or {$.wawa$}.

Built-in variables work just like regular variables, except you don't have to specify the content for them in the variables list.  Instead, CityDesk provides the content automatically.  These are {$now$}, {$publishTime$}, etc.

From a practical standpoint, they all get replaced with real content at publish-time, the difference is just where the content comes from.

Emperor Norton
Friday, March 19, 2004

Hi Darren.  Thanks; that's what I THOUGHT, but I wanted confirmation from someone.

rick

Rick Chapman
Friday, March 19, 2004

*  Recent Topics

*  Fog Creek Home