Problem editing

Permalink
Hi, I haven't been on my site to edit it for a couple f days. Today when using the dashboard to edit any page I keep getting the following error
An unexpected error occurred.
Declaration of Concrete\Package\EasyImageSlider\Block\EasyImageSlider\Controller::registerViewAssets() should be compatible with Concrete\Core\Block\BlockController::registerViewAssets($outputContent = '')

Can anybody tell me how to sort this please?

 
mnakalay replied on at Permalink Best Answer Reply
mnakalay
it looks like your host switched to PHP 7

You need to modify a file.

On your server, go to
packages/easy_image_slider/blocks/easy_image_slider and open the file controller.php

Look for the function
public function registerViewAssets()

And modify it to be like this
public function registerViewAssets($outputContent = '')

Then save and the problem will go away
swinn replied on at Permalink Reply
I have modified that file and am still getting the same error...


public function registerViewAssets($outputContent = '')
    {
        $this->requireAsset('css','easy-slider-view');        
        $this->requireAsset('javascript', 'jquery');
        $this->requireAsset('css', 'font-awesome');        
        $this->requireAsset('javascript', 'owl-carousel');
        $this->requireAsset('css','owl-theme');        
        $this->requireAsset('css','owl-carousel');        
//      $this->requireAsset('css','animate');
    }
mnakalay replied on at Permalink Reply
mnakalay
Did you empty concrete5's cache? and are you absolutely sure it is the same message, the same problem might exist in more than one package.
swinn replied on at Permalink Reply
How do I clear Concrete5 cache?
this is the message I am getting

Declaration of Concrete\Package\VividThumbGallery\Block\VividThumbGallery\Controller::registerViewAssets() should be compatible with Concrete\Core\Block\BlockController::registerViewAssets($outputContent = '')
mnakalay replied on at Permalink Reply
mnakalay
so it's the same error but with a different package and block. You need to do the same thing as before but this time for the package vivid_thumb_gallery and inside it the block vivid_thumb_gallery

I don't think you'll need to empty the cache as the first error is gone but it's something important to know.

Any time something seems not right on your site, emptying the cache is the first thing to try.

To do that you can use the intelligent search function. When logged in you have your top toolbar with a text box in the right hand. Type "cache" in it and you will see a few choices including "Clear Cache". Click on that and it will take you where you can easily clear the cache.

Keep that intelligent search option in mind it is extremely useful :)
swinn replied on at Permalink Reply
Thanks very much...I have sorted the line in vividthumbs and problem has gone away...
mnakalay replied on at Permalink Reply
mnakalay
You're very welcome