template placed into the tmpl folder for email plugin not showing up in dropdown

Status
Not open for further replies.

wqwi853

Member
I created an html template for the email plugin for a form I have. I uploaded the html file into the /plugins/fabrik_form/email/tmpl folder but it doesn't show up as a option in the PHP/HTML Template dropdown.

Does anyone know why this would happen?
 
I can't replicate this, and we use the built in JFormFieldFilelist type for that setting, so building the dropdown of files is all handled by Joomla.

Maybe check permissions on the uploaded file?

-- hugh
 
I presume you've reloaded the form edit page since putting the file in the folder?

I really don't have anything else to suggest. That dropdown is built by Joomla, not by us, from the files returned here:

https://github.com/joomla/joomla-cms/blob/staging/libraries/joomla/form/fields/filelist.php#L212

We don't specify a filter in our XML ...

Code:
            <field name="email_template"
                type="filelist"
                description="PLG_FABRIK_FORM_EMAIL_TEMPLATE_DESC"
                directory="/plugins/fabrik_form/email/tmpl/"
                hide_default="1"
                label="PLG_FABRIK_FORM_EMAIL_TEMPLATE_LABEL"
                repeat="true" />

... so JFormFieldFileList should just return the full list of files in that folder.

Try putting another file in there, maybe a .php, see if it makes any difference.

And double check you are looking at the right copy of Joomla.

-- hugh
 
@cheesegrits thank you so much for bearing with my stupidity. I figured out the problem. I was looking at the wrong /plugin/ folder the entire time. I was looking in the plugins folder within the administrator folder and not the root of the website. I figured this out by changing the filename of one of the php files and saw that it didn't change in the dropdown.

I did a find command and saw that there are two different plugin folders and realized my mistake.

Thanks again @cheesegrits
 
Status
Not open for further replies.
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top