-
Notifications
You must be signed in to change notification settings - Fork 446
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
using variable in template <include> directive. #1280
Comments
It's documented right that.
The real explanation behind is, that it's way more complex for template directives to handle such a case, and it must be implemented in every directive itself, hence there's no one fits all solution. The main template directives that come with F3 only supports static string or token usage for its attributes and no mixed usage.. at least it's documented right that.. hence you have to use the string concatenation within the token to make it work. |
Thanks Christian.
Note: the W3tpl is a shared libray. So when using a shared template from the library, I have to define the path from the base UI so I step one folder back. |
Within a template I defined a awLib as a directory with
<set awLib="./awLib/"/>
and the I can use it as a variable inside
src="..." or href="..." in HTML and <script> directive.
These line Work!
However, it does not work when I try to use the var (in the same way) in a template or directive.
The following line DOES NOT WORK!
<F3:include href="{{@awLib}}page_header.tpl" />
The only way to make it work it to use it as concatenated string.
The following line WORKS!
<F3:include href="{{@awLib.'page_header.tpl'}}" />
Any explaination?
The text was updated successfully, but these errors were encountered: