Joomla 3.7 fields_plugin question

23 views
Skip to first unread message

Ruud van Lent

unread,
May 22, 2017, 11:21:15 AM5/22/17
to Joomla! General Development
Hi,

does anybody know if it is possible to limit a plg_fields_[customfield] to a extension?
I am creating a custom field plugin so the user can upload an avatar (inclusive cropping etc.), but it is also possible to set this field to articles (which is 'useless').

Is it possible to set some 'value' in the plugin so the plg_fields_[customfield] can only be used in e.g. com_users?

Allon Moritz

unread,
May 22, 2017, 11:34:42 AM5/22/17
to joomla-de...@googlegroups.com
This would be a new option on the field. But com_fields is working with contexts, so com_fields needs to be changed the way, that it is going to search fields based on a context.

--
You received this message because you are subscribed to the Google Groups "Joomla! General Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to joomla-dev-general+unsub...@googlegroups.com.
To post to this group, send email to joomla-dev-general@googlegroups.com.
Visit this group at https://groups.google.com/group/joomla-dev-general.
For more options, visit https://groups.google.com/d/optout.

Ruud van Lent

unread,
May 23, 2017, 5:28:08 AM5/23/17
to Joomla! General Development
Hi, laoneo, thanks for your reply!
When an administrator adds the custom field designed for com_users to com_content, then it would still work correctly I guess. Was wondering if there was a setting that I missed :)
Not sure what is involved in adding this as an option, so not sure if there is a 'business case'...
Reply all
Reply to author
Forward
0 new messages