Welcome Guest, Not a member yet? Register   Sign In
Codeigniter 4 - Naming Convention & Style Guide

I don't think there is any significance at all, it just looks pretty in the source tree.

I would suggest that you have a style and you stick with it for your own projects.

I use the View as per CI4 and then all my subfolders are all lower case and I put a - dash in where I want to separate words.

The only place it really matters is in the controller names and the real problem comes when you want to use a - or _ in the url. In this case it them must be:

Cool_controller.php with a class name of Cool_controller()

But be very careful if you are developing under Windows, because Windows will not care about case, but then when you deploy under Linux it will care and any sloppiness with regard to case will cause all kinds of confusing errors. Like files not found, controllers not found etc.

Even when developing on a Mac, this can still cause problems.

Messages In This Thread
RE: Codeigniter 4 - Naming Convention & Style Guide - by Chroma - 08-27-2020, 04:52 AM

Theme © iAndrew 2016 - Forum software by © MyBB