Render a Custom Fields manually

Joomla offers some content events which are triggered during the content creation process. This is the place to define how the custom fields should be integrated into content.

When you don't want to use the triggers to render the custom fields automaticly, you can set this option to NO and create an override. How to do this can be read on this page:

In the override you created you need to enter the following code at any place you want to render the custom field.

<?php if (isset($this->item->jcfields[X])): ?>
<?php echo FieldsHelper::render('com_content.article', 'field.render', array('field'=> $this->item->jcfields[X])); ?>
<?php endif; ?>

[X] is the ID of the custom field

in this case this need to be replaced by: [1]

Last updated