A message from our CEO about the future of Stack Overflow and Stack Exchange. Read now.

New answers tagged

1

(This answer has been updated from the original which suggested hacking Joomla code, to this much better solution proposed in the comment below - thanks to @Irata!) Joomla includes the custom fields by means of a plugin which is triggered on onContentPrepareForm. This solution involves writing a second plugin, also triggered on onContentPrepareForm, which ...


1

If you're extending JFormFieldList then you don't need to use JHtml::_('select...) as well. Instead you just return an array of text/value combinations for the options of the HTML select. You can specify the default values by setting the protected variable $value. class JFormFieldCustomfield extends JFormFieldList protected $type = 'Customfield'; public ...


Top 50 recent answers are included