Saturday 20 July 2019

php - Codeigniter error: Parse error: syntax error, unexpected


Parse error: syntax error, unexpected '(', expecting identifier (T_STRING) or variable (T_VARIABLE) or '{' or '$' in C:\xampp\htdocs\code\application\controllers\user.php on line 14






class User extends CI_Controller
{

public function __construct()
{
parent:: __construct();
$this->load->model('user_model');
}


public function get()
{
$this->user_model->(2);
}

No comments:

Post a Comment

php - file_get_contents shows unexpected output while reading a file

I want to output an inline jpg image as a base64 encoded string, however when I do this : $contents = file_get_contents($filename); print &q...