I’m building a component that sends email messages in certain situations. I would rather not have the email HTML directly within my php code, therefore I would like to put the html into a .inc file. I’m not sure if best practices dictate where such files should be placed…the media folder perhaps? Thanks in advance!
I’m building a component that sends email messages in certain situations. I would rather
Share
The intent for the
/media/directory is that it contains all the assets you need to be “web visible” for your component. So if your component displays images, uses custom CSS, JS file etc that’s where they would go.The point of the media directory is so that in future updates to Joomla! the core code files can be moved to a non-web visible location to improve overall security.
Having said that if you will have executable or sensitive content in your
.incfiles then I would create aassetdirectory within the/administrator/components/com_yourcomponenet/.