Group Abstract Group Abstract

Message Boards Message Boards

0
|
7.6K Views
|
0 Replies
|
0 Total Likes
View groups...
Share
Share this post:

TemplateEnvironment

Posted 11 years ago

Here is a simple template:

template = XMLTemplate["
   <html>
    <body>
        <center> <wolfram:slot/> </center>
    <body>
   </html>"];

The following works fine and is understood:

SystemOpen @ Export[ 
    "e:\\folder\\page1.html",
    Rasterize[Plot[Sin[x], {x, -3, 3}]], 
    "HTMLFragment", 
        "TemplateFunction" -> template
  ]

Now the sample from the documentation:

SystemOpen @ Export[ 
    "e:\\folder\\page1.html",
    Rasterize[Plot[Sin[x], {x, -3, 3}]], 
    "HTMLFragment", 
    "TemplateEnvironment" -> <|
           "Theme" -> "Blue",
           "Brand" -> "mybrand",
           "PageTitle" -> "my pagetitle",
           "PageDescription" -> "This is a sine plot",
        "Footer" -> "The footer"
        |>
  ]

It uses "TemplateEnvironment". The question is where can I find the source template file where the above key value pairs are used. Can't find where it picks up the html template file to merge it in.

Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard