8 votes
Accepted

Getting custom fields and their values (com_fields)

The key here (which I misunderstood/overlooked) is that for the FieldsHelper::getFields method, to also return the value & rawvalue of the custom fields, the $item has to be a content item object. ...
FFrewin's user avatar
  • 19.6k
5 votes

Getting custom fields and their values (com_fields)

For getting custom fields and values for Joomla articles, you can use the following code: <?php JLoader::register('FieldsHelper', JPATH_ADMINISTRATOR . '/components/com_fields/helpers/...
Mayank Sahu's user avatar
5 votes
Accepted

How to fetch joomla article custom fields in another component?

You can use the following code to fetch custom field values by article id <?php JLoader::register('FieldsHelper', JPATH_ADMINISTRATOR . '/components/com_fields/helpers/fields.php'); //load ...
Mayank Sahu's user avatar
5 votes
Accepted

How to generate a dynamic note field for a custom component?

Use Form::setFieldAttribute(). Typically, this is done in the model's getForm() method. However, if it's cosmetic only, it can be done in the view too. In /administrator/com_image/models/forms/image....
Sharky's user avatar
  • 10.5k
4 votes
Accepted

How to remove the default editor inserted in a custom module

Please check if your custom module XML file contains the following line: <customContent /> This line is present in the default Joomla Custom HTML module, and inserts an editor field in the ...
johanpw's user avatar
  • 13.3k
4 votes
Accepted

Adding custom fields to com_content category

Yes, you can add custom fields to the com_content (category? I assume you intend component?): https://docs.joomla.org/Adding_custom_fields_to_core_components_using_a_plugin https://zunostudios.com/...
pixx's user avatar
  • 130
4 votes

Joomla Custom Fields Module / Matrix

There are a few options for this, the two best are probably FieldsAttatch and DPFields. I've used FieldsAttatch for a few years, and it has a nice light approach. However the newer DPFields looks ...
AndyGaskell's user avatar
4 votes

How to fetch joomla article custom fields in another component?

This function will allow display of JCFields anywhere in any extension desired, including templates. The first parameter is the only requirement and will dump the JCF data, based on the item ID ...
Nadal's user avatar
  • 188
4 votes
Accepted

How to show list of articles filtered by category and custom field

You can filter on Custom Fields via multiple ways: filtering via JavaScript + CSS. This will load all articles, but can CSS hide (display:none) them using some JavaScript. The articles are still ...
pe7er's user avatar
  • 1,918
3 votes

Custom 'dynamic' form field creation

I am using the following to achieve something similar to what you need BUT in a plugin. Need to confirm if it is also valid to component. <field name="list_field_name" ...
n.h.'s user avatar
  • 871
3 votes
Accepted

Dynamic fields in module parameters

No answers here, but I have managed to work it out for myself. The answer is actually to use both of the solutions I had in mind already -- a custom field type and a subform. My solution works like ...
Simba's user avatar
  • 610
3 votes
Accepted

Customize Global Configuration

First: Use a current Joomla. Your 1.5 site will be hacked in no time. Second - the answer (Joomla 2.x - 3.x): You can add component params to the component configuration. (You can access the ...
Dennis Heiden's user avatar
3 votes
Accepted

Custom field colResizable plugin not working but works in fiddle

You are calling the colResizable jQuery plugin before the jQuery itself. It should be the other way round. Also, Joomla's admin should also already have jQuery loaded, but that uses jQuery v1.12.4. ...
RichardB's user avatar
  • 3,072
3 votes

How to retrieve active filter from a custom field form?

Thank God for 5 year old posts and Occam's Razor. The Custom Field has direct access to the form that I was trying to get to!!!! No need to load a model, helper, or otherwise. $MyField1 = $this->...
GDP's user avatar
  • 7,705
3 votes
Accepted

Custom Fields inside module override

The label is in the 'fields' table so you could pull them with the values in a single query by using a join, eg. $db = JFactory::getDbo(); $query = $db->getQuery(true); $query->select('a.value,...
jamesgarrett's user avatar
  • 3,279
3 votes
Accepted

Joomla 4 - how to set namespace for custom field addfieldprefix

To implement Joomla standard namespacing in a plugin, follow these steps: First, declare extension's namespace in manifest file: <namespace>Joomla\Plugin\EditorsXtd\Vimeo</namespace> If ...
Sharky's user avatar
  • 10.5k
3 votes
Accepted

How to change custom field order in field group?

The order of the fields in the field group is determined by the order the fields appear in the fields page. You can therefore use the up/down arrows on the left to drag and drop the fields in the ...
Irata's user avatar
  • 3,467
3 votes
Accepted

How to programmatically set the value of a custom field of type checkbox?

Basically you needed to use onContentAfterSave rather then onContentBeforeSave and use the FieldsHelper in conjuction with the FieldsModelField. Here is the code: <?php defined( '_JEXEC' ) or die(...
mralexandrelise's user avatar
3 votes
Accepted

How can I create my own custom field?

I think you might be right there aren't direct official tutorials on this. But in the Joomla! documentation there is a hint. A developer focused pdf from the creator of custom fields Allon Moritz ...
mralexandrelise's user avatar
3 votes

Layout override for repeatable subform custom field

This helped me to solve my problem... <?php $fieldX = json_decode($this->item->jcfields[X]->rawvalue, true); ?> where X is the Id of the subform native field A, B, C is the respective ...
Chinecherem Kalu's user avatar
3 votes
Accepted

Creating a field plug-in, need the com_content form to be enctype multipart

There really isn't a good way to do this. Your best bet is parsing the already generated HTML and making a replacement there. For the component this can be done using onAfterDispatch event. Below is a ...
Sharky's user avatar
  • 10.5k
3 votes
Accepted

J4 - Custom Profile Plugin - Hiding Groups

I don't think it's safe to remove field groups based on fieldset names. They are unrelated and could be named differently, leading to unexpected results. And that is exactly the issue you're running ...
Sharky's user avatar
  • 10.5k
3 votes
Accepted

Dynamically add option to Jform field

You're already aware of Joomla\CMS\Form\Field\ListField::addOption() method. value is an attribute in the XML so it needs to be passed along with other attributes in the second argument: $this->...
Sharky's user avatar
  • 10.5k
3 votes
Accepted

How to get an article id in blog category view inside fields plugin

Field value is rendered during onCustomFieldsPrepareField event which takes 3 arguments: the context string, content item object and the field object. The content item is the second argument passed to ...
Sharky's user avatar
  • 10.5k
2 votes
Accepted

DPFields display values in module

Glad you like it. If you just need the value, then use the field model as you can see here https://github.com/Digital-Peak/DPFields/blob/master/com_dpfields/admin/helpers/dpfields.php#L137. Keep in ...
Laoneo's user avatar
  • 503
2 votes

Custom field colResizable plugin not working but works in fiddle

How about to change the $ sign with jQuery? So the code would be jQuery("#tableResizable").colResizable({ fixed:true, liveDrag:true, gripInnerHtml:"<div class='grip'>&...
webchun's user avatar
  • 2,418
2 votes

Custom Fields in component Articles - Joomla 3.6.4

Try Joomla 3.7.*, custom fields option is included in it. Read article for help https://www.joomshaper.com/blog/how-to-use-joomla-3-7-custom-fields
Mayank Sahu's user avatar
2 votes

Custom Fields in component Articles - Joomla 3.6.4

You might want to try digital peaks' dpfields. This is the extension where the 3.7 custom fields are based on. It will probably be possible to migrate from dpfields to j3.7! core custom fields. https:/...
Wim de Ruijter's user avatar
2 votes

Custom Fields in component Articles - Joomla 3.6.4

I have used Fields Attach on a few projects and it worked well. https://extensions.joomla.org/extension/fieldsattach http://fieldsattach.com
YellowWebMonkey's user avatar
2 votes

Custom Fields in component Articles - Joomla 3.6.4

Custom field will be supported natively in the upcoming Joomla 3.7. But if you're in hurry, you can try Aixeena Plugin
webchun's user avatar
  • 2,418

Only top scored, non community-wiki answers of a minimum length are eligible