https://github.com/fauzan1892/php-mvc-codekop
A simple open web project using php mvc frameworks from Codekop
https://github.com/fauzan1892/php-mvc-codekop
php php-pdo
Last synced: 7 months ago
JSON representation
A simple open web project using php mvc frameworks from Codekop
- Host: GitHub
- URL: https://github.com/fauzan1892/php-mvc-codekop
- Owner: fauzan1892
- Created: 2020-01-05T04:11:12.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2020-10-19T12:12:25.000Z (almost 5 years ago)
- Last Synced: 2025-01-14T08:22:41.851Z (9 months ago)
- Topics: php, php-pdo
- Language: PHP
- Homepage:
- Size: 79.1 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Codekop PHP MVC Codekop Version 1.0 ( Beta )
A simple open web project using php mvc frameworks from Codekop## Starter Apps :
setting base url on index : app/Config/Config.php
$config['base_url'] = "http://".$_SERVER['HTTP_HOST'].preg_replace('@/+$@','',dirname($_SERVER['SCRIPT_NAME'])).'/';## Default Controller
setting default controller : app/Config/Routes.php
$routes['DefaultController'] = 'Home::index';## Setting Database
setting database : app/Config/Database.php
$dbhost_ = 'localhost'; // host your server
$dbname_ = ''; // your database name
$dbuser_ = 'root'; // user your server
$dbpass_ = ''; // pass your server## Model View Controller
create models in codekop framework on app/Models
create controller in codekop framework on app/Controllers
create views in codekop framework on app/Views :
how to use views in controller example :
// controller
public function index()
{
$data['title'] = 'Selamat datang di codekop php mvc';
$this->show->view('welcome_view', $data);
}## Contributors