Marco Dings
Custom fields 4 Joomla
Joomla! Day UK 2016
London, Cardinal palace
Februari 13th 2016
J3.?
About me
Marco Dings ( PLT )
@mdings
J!4 Project Manager
CTO Virya Group
Conception
From DPFields to “JFields”
JFields does not exist yet ( J3.? )
Based on and compatible with DPFields
Contributed by Digital Peak
Allon Moritz
Benefits of Custom Fields
Add user defined data elements, fields to content elements
Extend standard Joomla extensions
Users,
Articles and
Modules
Custom visualisation of Fields, where and how
Support Joomla compliant extensions out of the box
Custom Fields Joomla basics
Searchable
Multilingual
Custom extensions can be extended with custom fields
Why Custom Fields
Extend content in simple way
Display content consistently, and customised
Support Joomla compliant extensions out of the box
Custom extensions can be extended with custom fields
What’s in it for me?
Extend user profile with
Avatar
Country
Telephone
What’s in it for me?
Display user-fields in article based on author
What’s in it for me?
files
youtube video by id
urls
mysql


What would you like to add
Custom Fields characteristics
Fields similar (not yet “extended” from Joomla core)
Still difficult to add your own fields
Flexible standard visualisation using backend GUI
Custom visualisation requires “templating skills”
Available fields
Current selection
Media
Article
Radio
Sql
Telephone
Text
Textarea
Timezone
Url
Calendar
Captcha
Checkboxes
Color
Editor
Email
Image
Integer
List
User
Usergroup
Yes No
DPCalendar Calendar
Installation
While not in Joomla core get it from
https://joomla.digital-peak.com/download/dpfields
Configuration
Plugin
Hide components
Default visualisation
Configuration
(Default) visualisation
After title
Before content
After content
Fields and Field Categories
Fields ( hold your data )
Field Categories are used
to group fields for input,
appear as named tabs
with the item
Fields
Fields displayed sequentially
No conditional fields
Field Categories
One Tab per Field Category
Tab named after Field Category
One or more tabs
When fields are displayed
Categorie and Tags
Fields can be assigned to
Categories ( multiple )
Tags
Fields will only show in the defined
context of category or tags
Where to display
Basic Layout
Editor Button
Advanced
Basic Layout
After Title
Before Content
After Main
none
Editor Button
Editor Button
Use editor plugin
Will open list with fields
Editor Button
Select field
Code gets inserted
{{#dpfields id=9}}{{value}}{{/dpfields}}
Portability
{{#dpfields id=9}}{{value}}{{/dpfields}}
Should be using fieldname iso id value for portability of content
Same fields in different installations could have different id’s
Use alias
{{#dpfields alias=avatar}}{{value}}{{/dpfields}}
Advanced display options
Changing appearances
‱ Template overrides
‱ Alternate layouts
‱ Jlayout
Template overrides
Change the default behaviour of content
https://docs.joomla.org/How_to_override_the_output_from_the_Joomla!_core
Hoe the article, blog .. shows for your template
Create via the
backend
Templates/[templatename]/html/

Alternate layouts
Add alternate layout
NO backend GUI 
In addition to Template overrides
Can be selected for the content in article, menu definition
Change the default behaviour of content
https://docs.joomla.org/How_to_override_the_output_from_the_Joomla!_core
Combining with other
Overcome limitations with 3rd party
Articles anywhere
{articles cat:bedrijven}{layout:bedrijven}{/articles}
Blog layout with article alternate layouts
JLayouts
Building blocks of views
https://docs.joomla.org/J3.x:Sharing_layouts_across_views_or_extensions_with_JLayout
Title
Pagination
Readmore
Fields
JLayouts template overrides
template
Add you layouts to
Templates/[templatename]/html/

JLayouts components overrides
Have different fields representation per component
The same Field-type could have a different representation for
users as opposed to articles
Templates/[templatename]/html/component/[
Code snippits
Samples of code to use in your overrides
More and downloadable content from
http://viryagroup.com
Code snippits
Image in article
Code snippits
Use aliases instead of id’s
Simply map them once
Use your own JLayouts
Custom Fields in Joomla - JoomlaDay UK 2016 - Marco Dings

Custom Fields in Joomla - JoomlaDay UK 2016 - Marco Dings