Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- defined('BASEPATH') OR exit('No direct script access allowed');
- class Welcome extends CI_Controller {
- public function index()
- {
- $this->load->view('welcome_message');
- }
- public function database()
- {
- $query = $this->Model_front->cari_brand(); //query model
- $kota = array();
- foreach ($query as $d) {
- $kota[] = array(
- 'message' => $d->name_brand,
- );
- }
- echo json_encode($kota);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement