Re: Problem with using variable in <?cs include: ?>
Brandon Long <[email protected]> Fri, 29 Aug 2008 14:26:23 -0700
| Newsgroups | gmane.text.clearsilver.general |
|---|---|
| Organization | Fiction L Networks |
| Message-ID | <20080829212623.GB14056@bl1> |
On 08/29/08 petr.vorel uttered the following other thing:
> Hello,
>
> I've got a problem with using variable in <?cs include: ?> in template.
>
> I can include file
> <?cs include: "path_to_file/file.tmpl" ?>
>
> I've defined in perl script:
> $hdf -> setValue("Page.Template.Menu", "path_to_file/file.tmpl");
>
> In template, I can also print variable containing full file name with:
> <?cs var:Page.Template.Menu ?>
>
> I'd like to use this variable in include.
> None of these works:
> <?cs include: Page.Template.Menu ?>
> <?cs include: $Page.Template.Menu ?>
> <?cs include Page.Template.Menu ?>
> <?cs include $Page.Template.Menu ?>
The correct syntax is:
<?cs include:Page.Template.Menu ?>
or this:
<?cs include!Page.Template.Menu ?>
The exclamation point means "required", and if it fails to include the
template, it should raise an error telling you why.
Brandon
--
"For some reason, the act of talking to Absolute Evil makes chocolate
syrup drip from your pineal Gland."
-- LeTeXan, "Today's Suck" 6/3/97
http://www.fiction.net/blong/