We are constantly trying to improve PHP Freaks and these forums, so feel free to go to the PHPFreaks Comments/Suggestions board and point out anything you'd like to see different!
0 Members and 1 Guest are viewing this topic.
I do use objects in my code. I am relating GET variables to objects but within a switch statement. Is that how you would do it?
<?php $controller = $_GET['c']; $action = $GET['a']; if (file_exists("controllers/$controller.class.php")) { include "controllers/$controller.class.php"; $obj = new $controller; if (is_callable(array($obj, $action))) { $obj->$action(); } }?>