Description
Allows you to use WebMacro
to define page templates for your blog.
Installation and Configuration
You must download the blojsom add-on bundle. It is available as a separate download with each release of blojsom.
- Unpack the add-on bundle ZIP file.
- Copy the webmacro-2.0.jar and concurrent.jar files to your blojsom installation's /WEB-INF/lib directory.
In your /WEB-INF/classes/blojsom.xml file, add the following:
<bean id="wm" class="org.blojsom.dispatcher.webmacro.WebMacroDispatcher" init-method="init">
<property name="webMacroProperties">
<ref bean="defaultWebMacroProperties"/>
</property>
<property name="blojsomProperties">
<ref bean="defaultProperties"/>
</property>
<property name="servletConfig">
<ref bean="servletConfigFactoryBean"/>
</property>
</bean>
The defaultProperties bean should already be configured.
<bean id="defaultProperties" class="org.springframework.beans.factory.config.PropertiesFactoryBean">
<property name="properties">
<props>
<prop key="default-blog">default</prop>
<prop key="ignore-flavors">admin, rsd</prop>
<prop key="installed-locales">de, en, fr, jp, ko, pt_BR, sv, zh_CN</prop>
<prop key="resources-directory">/resources/</prop>
<prop key="templates-directory">/templates/</prop>
<prop key="themes-directory">/themes/</prop>
<prop key="blogs-directory">/blogs/</prop>
<prop key="bootstrap-directory">/bootstrap/</prop>
</props>
</property>
</bean>
You will need to configure the defaultWebMacroProperties bean similar to the defaultProperties bean. This is where you would configure WebMacro options.
Usage
You can find a reference for the WebMacro template language
online.