5

My Acl admin is corrupt and I have no idea why, since I haven't changed anything from when it used to work.

When I go to /acl, I get the following error:

Error: Class 'String' not found File: /app/Plugin/Acl/Controller/Component/AclReflectorComponent.php
Line: 17

public function getPluginName($ctrlName = null)
{
    $arr = String::tokenize($ctrlName, '/');   <-----  Line: 17
    if (count($arr) == 2) {
        return $arr[0];
    } else {
        return false;
    }
}

I checked what's in $ctrlName and the value is Acl/Acl.

I'm completely lost here, what should I do?

Inigo Flores
  • 4,461
  • 1
  • 15
  • 36
flaggalagga
  • 451
  • 5
  • 14

1 Answers1

15

In order to make CakePHP compatible with PHP7, the String class has been deprecated as of CakePHP 2.7 in favour of the CakeText class.

You have to download an up to date version of your Acl Plugin.

If you can't find one, changing all occurrences of String with CakeText should fix the problem.

Inigo Flores
  • 4,461
  • 1
  • 15
  • 36