1084

Naming directories

Comments for “Naming directories”
 

Posted by delta13dek on Sunday 18th February 2024 at 20:51 GMT

I noticed I named my 'controllers' folder (or directory) a different name (originally a typo) inside my modules folder - I got a 404. I found the typo and named it 'controllers' and the error went away. Why is this? Is this a Trongate thing?
Level One Member

delta13dek

User Level: Level One Member

Date Joined: 14/02/2024

Posted by DaFa on Monday 19th February 2024 at 05:05 GMT

Hi, modules are just folders inside your app. The structure of a module MUST contain a folder called 'controllers', with an optional 'views' and 'assets' folder. If you look in core.php you will see Trongate scans for the 'controllers' folder and if it doesn't exist, you will be shown the red 404 page. Please also check the docs if you haven't already, as it is very clearly explained.

This comment was edited by DaFa on Monday 19th February 2024 at 05:56 GMT

Founding Member

DaFa

User Level: Founding Member

Date Joined: 30/11/2018

×