How do I create a custom template?

cheesegrits

Support Gopher
This is NOT a comprehensive guide to customizing templates! It is just a simple description of how to start the process.

You should NEVER edit the standard templates that come with Fabrik. If you do this, you will lose all your changes the next time you update Fabrik.

Pick the table or form template you wish to base your custom template on. We'll use 'bluesky' as our example.

Find the directory for the template you want to base your customization on. The 'bluesky' form template is in ...

./com_fabrik/views/form/tmpl/bluesky

The table template is in ...

./com_fabrik/views/table/tmpl/bluesky

Copy the entire 'bluesky' directory (either form, table or both depending on what you want to customize) and rename the new folder to whatever you want your new template to be called, lets call it 'foosky'.

If there is a bluesky.js file in the your new folder, rename it to foosky.js.

Your 'foosky' template should now magically appear on the list of available templates for your form / table.

Now of course comes the harder part, which is to apply whatever changes you need to the template. This might be as simple as modifying the CSS (template.css) to change the colors, or it might be some radical surgery to the template code (template.php) to totally change the way the form / table is rendered. But that's up to you, and not covered in this simple How To!

-- hugh
 
Greetings!

Where is the info on how the table/form is rendered? I need to have tables and forms with right aligned numbers and currency.

Thanks!
 
I am a newbie. What is the URL jump page? I tried the URL associated with the page table, and whenever I used the form, it takes me to the edit table page.
Thanks.
 
Your 'foosky' template should now magically appear on the list of available templates for your form / table.
Hi,
I've duplicated the default folder in www/components/com_fabrik/views/table/tmpl/, I've renamed it and it doesn't magically appears as a choice in the dropdown menu...
Potter? where are you?

edit : ooops, I'm on 2.1, I will post it elsewhere...
 
We are in need of some funding.
More details.

Thank you.

Members online

No members online now.
Back
Top