Creating your own template

Add your own code to create new template / effects.

InDesign page items can be assigned a template / effect. The available effects are listed in the Exporters template menu. To add a new effect create your HTML / CSS and place it in the appropriate item folder in the Exporters folder. Your new effect will automatically be included in the template menu. You will also have to create a java script 'nugget' that will be called from the Exporters engine to implement your HTML. The java script can also be used to set variables that your HTML might use.

When the user assigns your new template / effect to a page item your java script will be called to add controls to the Exporters panel. These 'controls' can be: popups, checkboxes, static texts, editable texts.... The values of the controls are stored in the InDesign page item ready for export.
Indesign baker export panel showing google maps templage
The above is showing the Google Map template. The Latitude and Longitude fields were added by the associated script.

When the InDesign document is being built or previewed your java script code will be called to inject your HTML / CSS into the output stream.

Here is a sample 'nugget'.

If you don't like the way we export some thing, simply write your own template and replace ours.

Here is some food for thought.

(Always check the ownership of any code you might use.)
Subpages (1): Sample