Cakephp 4.x Function with underscore

Cakephp is automatically changing may function name .
In first picture my function name is “customer_logs__index”.
But in the second picture it becomes “customerLogsIndex”.
How to avoid this sudden change in my function name ?

image

I think this is due to the Cake Conventions, described here:
https://book.cakephp.org/4/en/intro/conventions.html#view-conventions

What maybe could help, if you want to keep the name of your controller action, is to define routes to the controller action.

@dirk Thanks for the reference , this is exactly the problem i am trying to fix .
Can you help me how can i disable the Cake convention for methods .

I don’t suppose conforming to the standard is an option?

There are many discussions between camel-case, double-humped camel-case (Pascal style), and underscore separated - but the answer is use the style that the language designers intended. There can be unexpected repercussions when not. For instance underscore has certain meanings in some languages, especially if your variable/procedure starts with one.

From looking at your example you have underscores in a URL, of which the world says: don’t! google.com/search?q=underscore+in+url Maybe using a dash if you must use anything - but I don’t know what Cake would do to that either!

I guess i don’t have a choice but to follow the standard option . Thank you