Invalid CityDesk Syntax
Problem: Trying to publish a site produces the following error message:
Invalid CityDesk Syntax
There are many possible causes for this, but the most common is that something got inside the CityScript tags {$ and $} which is not valid CityScript.
Possible Cause #1:
The most common cause for this problem is when you have inadvertently put HTML tags inside a CityScript code block (i.e., between {$ and $}). For example, suppose you had the following CityScript code:
{$ .headline $}
If you are in Normal View, and you select the word .headline and make it Italic, it will show up like this:
{$ .headline $}
Although this looks OK in CityScript mode, the underlying HTML will actually contain:
{$ <EM>.headline</EM> $}
This is not OK because the CityScript parser doesn't know what to make of the <EM> which is not valid CityScript.
The solution for this is to edit the code in HTML View to move all HTML tags outside the CityScript blocks, for example:
<EM>{$ .headline $}</EM>
Possible Cause #2:
Errors like this can also happen if you have a {$ tag inside a file somewhere that is meant to be published as-is -- you didn't mean for it to open a CityScript tag. For example you might have a perl script which contains the statement URL{$_} which is perfectly normal perl but will confuse CityDesk.
There are two possible solutions for this.
-
Use {{$$}$ instead of {$. The extra {$$} in the middle is interpreted as a simple CityScript program which does nothing, and it manages to keep the first { far enough away from the $ to prevent further CityScript processing.
-
Put your perl scripts in files with a .pl extension, then use the Tools >> File Types dialog to configure .pl files as not containing code. If you do this CityDesk will never try to parse anything inside .pl files.
CityDesk Home
Fog Creek Home
Email Us