Catchable fatal error

Get this error:


What is wrong?

Is because PDO is in the global namespace? \PDO instead of PDO. So in your constructor method of CoursesController, you can import it at the top as use \PDO; and then you could reference it as just PDO if you want.

1 Like

Closed. My fail. Thanks!