Create your own layouts

Create your own layouts

Note: These features are part of the Visforms Subscription and are not included in the free Visforms version.

It is very easy to create your own layouts and use them for data display with the help of the plugin. Simply adapt one of the two existing layouts to suit your needs. Copy the existing layout and make changes to the copy. You only need 3 steps for this.

The layout files of the plugin are in the directory plugins/content/vfdataview/tmpl.

Step 1:

Copy one of the two existing layouts into the same directory, such as list.php.

Step 2:

Rename the copied file. for example in mylist.php.

Note: Please note that the file name must not contain underscores, but should ideally consist of one word.

Step 3:

Adjust the HTML of the layout file to suit your needs. Proceed as with a template override. For example, by adding your own class attribute to the HTML. Or by presenting the data in a completely different way that you like better than in a table or definition list.

To use the layout, now specify the "layout”:“mylist" parameter in the plugin string. This is the filename you chose without the .php extension.

That’s it!