Company | Newzulu Platform | Developer

Developer Template Documentation v4.12.2.47

Wrapper templates

Wrapper templates make up the base of every page. Every site must have a 'default' template. If you need different looks or uses for parts of your application you can create alternative wrapper templates.

Think of the wrapper as a combined footer and header for your application. Additionally, the separate wrappers can be created for text of HTML email formats. Common meta, CSS and JS information should be placed in your Wrapper. It controls everything except for the main content of a page.

A very basic example of a wrapper template:

     <title> UGC site - {$$pageTitle}</title>
     <fm:Switch value="{$$basepage}">
        <fm:Case value="entry">
            <fm:FileInfo mid="{$$}">
                <meta name="description" content="{$media.message}" />
                <meta name="title" content="{$media.title}" />

Supported Attributes

application.facebook_app_id The Facebook App ID of the Application. This can be set in the "General" tab of the Application Settings page.
basepage The current base-page. For example: "home", "entry", "mediadetail".
content The main content of the page. The Application Template for the current page replaces this var.
cssLoader This spits out the link for the CSS stylesheet required for styling the application. If the current page is a mediadetail page (Includes the module 'FMModule_MediaDetail') you can access the media ID of the current media using this var.
pageTitle The current page's title. This can be set in the Application Templates using the <fm:PageTitle> component.
subpage The current sub-page. For example, in "" the sub-page is "5467821".
vhost The URL of the current Application. This var doesn't include the protocol. Remember to add "http://" before.
vhostid The vhost ID to which the Application belongs.

Depricated Attributes

htmlheaders This spits out the page meta tags, CSS loader path and glbal vars in the head of the page.

The wrapper templates in our system are:

Creating a new Wrapper Template:

See Also:

<< 3.1.1 Application templates 3.1.3 CSS stylesheets >>