I am trying to add field path into
templateDetails.xml without specifying a templateName. The following code works
<fieldset name="name" label="label" addfieldpath="/templates/templateName/fields">
But I wonder if it's possible to do something like this
<fieldset name="name" label="label" addfieldpath="__DIR__/fields">
JHtml::_('script', '/templates/templateName/js/field.js' );
works fine, but giving it absolute path doesn't work
JHtml::_('script', dirname(dirname(__FILE__)).'/js/fieldName.js' );
JHtml::script is deprecated in Joomla 4, but is still not working for me for some reason.
Thanks for any hint/suggestion.