Note the upgraded forum! If you are experiencing issues logging in, you may need to reset your password which should send an email. If the email doesn't arrive, be sure to check your spam folder just in case.
Naming convention for Controller class?
I am new to Fuel CMS and I am really enjoy using this great framework.
I have a question about the controller class please.
I have a view name "contact-us"
In this case, I want to create a controller to process the form data please.
But since PHP class cannot have "-" in the class name.
What is the work around this for me to be able to create a controller for "contact-us" page?
My solution is,
I am thinking about using the route.php to set up like.
$route['contact-us'] = 'contact_us';
Then I need to create a controller file name "contact_us.php".
in the index method, I will call the view like,
public function index()
// load the fuel_page library class and pass it the view file you want to load
$this->load->module_library(FUEL_FOLDER, 'fuel_page', array('location' => 'contact-us'));
What would be the best solution to resolve this problem?
I have all of my view that contain "-" and most of the view need to process the data.
"How do you put the code in the forum? Do you use any tag?"
Thank you very much.