Getting Custom Extension Fields to Show on Override com_tags Tag View

by Justin Herrin   Last Updated January 04, 2017 08:04 AM

I have built a custom extension for the Joomla 3.x series and the extension uses the core Joomla Tags system to allow me to add Tags to my content items. I wish to override the look of the core com_tags Tag View menu item so I can display some fields from my extension within the override view.

As per the official Joomla documentation, I have previously added a record to #__content_types table for my extension and used the "field_mappings" column to match the "common" core fields to some of my extension fields and the remaining extension fields are matched up using the "special" array portion of the "field_mappings" column.

Next I created my override files... copied the core tmpl files into my own template's html directory, renamed, and edited as needed.

What I can not get to work successfully is getting the custom extension fields that were placed into the "field_mappings" column under the "special" array to show properly on the frontend. I can get any of the "core" fields to display just fine by using calls such as <?php echo $this->escape($item->core_title); ?> and <?php echo $this->escape($item->core_body); ?>, but not the "special" ones. Trying <?php echo $this->escape($item->myfieldname); ?> did not work.

I also tried seeing what is being returned by the tags component by using...

<?php print_r($item); ?>

... but none of the "special" fields show, only the "common" core ones.

Has anyone gotten this to work successfully before? I'd love to know how to get the "special" fields to display in the override view.

Thanks in advance!

Related Questions

Tags filter field - how to add custom "placeholder"?

Updated February 01, 2018 09:10 AM

Modify Joomla Tags Result Page

Updated March 27, 2015 14:19 PM

Modify similar tags module

Updated March 28, 2015 07:03 AM