Category Articles

Creating a Form2Content Template

Print

The Form2Content templates are very easy to make but have a few little things you should remember and apply.

Please do NOT edit the default Template created by Form2Content for every Content Type. This file is rewritten when new fields are added or edited. Simply upload a new template (.tpl or .html file) using the Template Manager of via FTP into media/com_form2content/templates directory.
If you open your default intro template file you can see all the Template Parameters of your custom fields of that Content Type.

File Format of the template files

The file format can be either .html or .tpl. All html markup and plugin codes can be inserted.

patTemplate Tags of your Template Files

Important: Place your custom code between the following patTemplate tags. These are your first and last line of code ... always!

... your code ....

Don't use any tags like body or head since the templates are just for html, added to the article body like in your normal Joomla! article editor.

Including your Template Parameters

Next add your template parameters. These are the (unique) Field Names of the custom Fields you added to your submission form.

Always add the name of the template parameters in CAPITALS

{COMPANY_LOGO}
{COMPANY_NAME}
{COMPANY_DESCRIPTION}
{JOOMLA_TITLE}

Including your custom layout

And last, include any styling you like within your template. Don't forget the great possibility of including plugins.


{COMPANY_LOGO}
Company name: {COMPANY_NAME}
{COMPANY_DESCRIPTION}

This shows the Article Title used in the Template: {JOOMLA_TITLE}.
Royalty Free Images
Verschillende betaalmethoden

Open Source Design

Ceresstraat 24
4811CC Breda
The Netherlands
+31(0)765152174