VASIM SETA
VASIM SETA

Reputation: 165

OctoberCMS error in frontend - frontend is not accessible firing error "Default value for parameters with a class type hint can only be NULL"

all I am new to OctoberCMS, i have installed already built project into my Ubuntu 16.04 system with PHP5.6 and apache2. I have successfully setup and run project backend after very hard trying. but problem is when i open any front-end URL then this error occurs:

Default value for parameters with a class type hint can only be NULL
/home/vasim/jannat/code/octoberdev2/plugins/look/casefiles/classes/ActivityLogger.php line 59

error screenshot

I have search it on Google and can not finding anything helpful and i have also find out that it is a rainlab plug-in error, I have uninstall and reinstall that plug-in but that also not worked. so, please can anyone help me with this error?

Any help will be appreciated.

Upvotes: 1

Views: 116

Answers (2)

Oli
Oli

Reputation: 1190

The most likely root cause of this is that the plugin was written in PHP 7.x, using typehint bool in the method signature. PHP5.6 doesn't support booltypehint and interprets bool typehint as class and thus the error.

You have some choices:

  • Upgrade your project to PHP 7
  • See if the plugin is available in PHP 5.x compatible version and use that instead
  • Remove the plugin altogether and find another with equivalent functionality
  • Remove the plugin and code equivalent functionality yourself
  • Fix the error in the plugin yourself (making it backward compatible) Heads up! It might break when you upgrade the plugin.

Upvotes: 2

Ahmed Essam
Ahmed Essam

Reputation: 1010

It seems an error from a plugin called look/casefiles. If it's not your own plugin try to remove it and the application should works well.

Upvotes: 1

Related Questions