Changed template variable stylesheetDir to themeStylesheetDir for clarity. Added examples of how to add a script from a body template. Pass themedir to ScriptList object.

This commit is contained in:
rjy7 2010-06-25 17:44:50 +00:00
parent 2ada3b7c35
commit df683191cf
4 changed files with 30 additions and 6 deletions

View file

@ -50,3 +50,4 @@
<@dump var="urls" />
<@dump var="fruit" />
<@dumpDataModel />

View file

@ -36,3 +36,22 @@
<#include "partials/scripts.ftl">
</body>
</html>
<#--
Three ways to add a stylesheet:
A. In theme directory:
${stylesheets.addFromTheme("/sample.css");
${stylesheets.add(themeStylesheetDir + "/sample.css")}
B. Any location
${stylesheets.add("/edit/forms/css/sample.css)"}
To add a script:
A. In theme directory:
${scripts.addFromTheme("/sample.js");
B. Any location
${scripts("/edit/forms/js/sample.js)"}
-->