muncul error saat welcome

Ditanyakan pada tanggal 30 November 2019 oleh Suryatna Sacadibrata

A PHP Error was encountered Severity: Notice

Message: Undefined property: Welcome::$welcome

Filename: controllers/Welcome.php

Line Number: 23

Backtrace:

File: C:\xampp\htdocs\sacashop\application\controllers\Welcome.php Line: 23 Function: _error_handler

File: C:\xampp\htdocs\sacashop\index.php Line: 320 Function: require_once

An uncaught Exception was encountered Type: Error

Message: Call to a member function view() on null

Filename: C:\xampp\htdocs\sacashop\application\controllers\Welcome.php

Line Number: 23

Backtrace:

File: C:\xampp\htdocs\sacashop\index.php Line: 320 Function: require_once

mohon bantuannya.

BUAT KOMENTAR

1 JAWABAN / 0 KOMENTAR

Generic placeholder image
Ahmad Oriza Sahputra menjawab pada tanggal 5 December 2019

Hai mas,

Pastikan penulisan controller sudah benar, seperti ini :

<?php
defined('BASEPATH') OR exit('No direct script access allowed');

class Welcome extends CI_Controller {

    public function index()
    {
        $this->load->view('welcome_message');
    }
}

Boleh share kode controller punya mas kesini ?

BUAT KOMENTAR