CodeIgniter: Showing Simple One DataTag: CodeIgniter, framework, mvc, database Category: PHP Frameworkpost: 26 Jan 2008 read: 2,482 CodeIgniter Step By Step Tutorial: After show all data, We learn how to show one data. We want a data with certain ID, example ID = 1. We still use same files with previous practice. For model: Open "employee_model.php" within CodeIgniter\system\application\models. Add following function:
For Controller: Open "employee.php" within CodeIgniter\system\application\controllers. Add following function:
For View: Open "employee_view.php" within CodeIgniter\system\application\views. Enter following code:
Now, test it. Point your browser to http://localhost/CodeIgniter/index.php/employee/get.
|
| | Give Your Opinion | Recommend |
|





