?
avatar artur-stepien
artur-stepien
23 Sep 2017

Steps to reproduce the issue

  • Create in your default template a file '/templates/YOURTEMPLATE/html/layouts/joomla/form/renderfield.php'
  • Remove anything in that file and put word "TEST"
  • Open any front-end form using Joomla\CMS\Form\Form (for example contact form in com_contact)

Expected result

Form inputs replaced with word TEST

Actual result

Nothing changed. Even changing the content of default layout (/layouts/joomla/form/renderfield.php) does nothing.

System information (as much as possible)

Joomla 3.8, PHP 7

Additional comments

Votes

# of Users Experiencing Issue
1/1
Average Importance Score
3.00

avatar artur-stepien artur-stepien - open - 23 Sep 2017
avatar joomla-cms-bot joomla-cms-bot - labeled - 23 Sep 2017
avatar eshiol
eshiol - comment - 4 Oct 2017

That because the include paths array is:

templates/<template>/html/layouts/<component>
components/<component>/layouts
templates/<template>/html/layouts
layouts

and com_contact has the own renderfield.php file
components/com_contact/layouts/joomla/form/renderfield.php

if you want to overrire the renderfield of the component com_contact you have to put the file renderfield.php into the folder
templates/<template>/html/layouts/com_contact/joomla/form

avatar artur-stepien
artur-stepien - comment - 4 Oct 2017

And why it is separated? It looks like a dirty fix for something that core would also be affected (or would need). Its against DRY principle in my opinion.

avatar franz-wohlkoenig franz-wohlkoenig - change - 4 Oct 2017
Status New Discussion
avatar brianteeman brianteeman - change - 5 Oct 2017
Status Discussion Closed
Closed_Date 0000-00-00 00:00:00 2017-10-05 12:57:14
Closed_By brianteeman
avatar brianteeman brianteeman - close - 5 Oct 2017
avatar brianteeman
brianteeman - comment - 5 Oct 2017

As it says in the code this is the reason why com-contact has a custom renderfield #8473

I am closing this as the reported issue has been answered by @eshiol

Add a Comment

Login with GitHub to post a comment