Làm thế nào để Uncaught TypeError. call_user_func(). Lập luận số 1 với các ví dụ

Trong bài viết này, tôi sẽ đưa ra 1 ví dụ minh họa về cách sử dụng Cách gỡ lỗi TypeError. call_user_func(). Đối số #1 với các ví dụ .

Làm thế nào để Uncaught TypeError. call_user_func(). Đối số #1 với các ví dụ - Lỗi loại không bắt được. call_user_func(). Đối số #1
// add static to the functions in your controller file like "ProductController.php" or whatever and it should work 

// like if your code looks like that:

class ProductController {

   public function index() {

       echo 'index page';

   }

}

// it should be like that:

class ProductController {

   public static function index() {

       echo 'index page';

   }

}


// and it should work fine 
// good luck and sorry for my bad english

Nhiều ví dụ khác xung quanh chủ đề Làm thế nào để Uncaught TypeError. call_user_func(). Đối số #1 với các ví dụ vui lòng xem thêm

chưa xác định