CityDesk 2.0-Documentation
Including One Article Inside AnotherWhen you are building sites, it's common to have a few blocks of text or HTML which need to be repeated identically in various locations throughout your site. There are three common ways to accomplish this: with templates, variables, or the {$ include $}statement.
The include statement is replaced with the body of any article. The syntax is:
{$ include "article" $}
article should be the complete path to an article within your site, separated by slashes (/) or backslashes (\). For example:
{$ include "Glossary/Copyright Notice" $}
To include an article from the top-level folder, start with a single slash, for example:
{$ include "/Copyright Notice" $}
If you don't provide any slashes, CityDesk will include all articles in any folder matching the name you specified.
In multilingual sites, include is language-aware. When generating a page in a given language, include will insert the version of the included article in the appropriate language. This is different from variables, which are the same in every language.
include can be used anywhere CityScript can be used, including in variables. For example we could create a variable named c defined as {$ include "Glossary/Copyright Notice" $}. Now throughout the site you can simply write {$.c$} to get the copyright notice from that article.
©Copyright 2001-2003 Fog Creek Software, Inc. All Rights Reserved.