-1

I'm launching the app using xampp, and this happen

Deprecated: Optional parameter $level declared before required parameter $message is implicitly treated as a required parameter in C:\xampp\htdocs\PHP-Point-Of-Sale-master\system\codeigniter\Common.php on line 270

also in this message appear

An Error Was Encountered Unable to load your default controller. Please make sure the controller specified in your Routes.php file is valid

the app is point of sale web based.

here's the code on line 270:

function log_message (string $level = 'error', $message, $php_error = true)

what should i do?, is there any big problem with the code or else?, thanks :)

user3783243
  • 5,368
  • 5
  • 22
  • 41
  • 2
    *"Optional parameter **$level** declared **before** required parameter **$message**"* - Your error is pretty clear; `$level` (optional, since you're setting a default) is defined before `$message` (required, since it doesn't have a default). Change your order: `function log_message ($message, string $level = 'error', $php_error = true)` – Tim Lewis Aug 14 '23 at 16:42

0 Answers0