Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

Upgrading SilverStripe /

Ask questions about upgrading SilverStripe to the latest version.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

CommentAdmin::EditForm()


Reply


5 Posts   854 Views

Avatar
Parker1090

Community Member, 38 Posts

4 March 2013 at 11:24pm

Edited: 04/03/2013 11:25pm

Hi All,
I downloaded a copy of SS 3.03, and trying to upgrade my site to this version.
I hit a few issues, which I've managed to get around, but now I'm stuck with this one, so any help will be massively appreciated!

[Strict Notice] Declaration of CommentAdmin::EditForm() should be compatible with that of LeftAndMain::EditForm()
GET /index.php/admin/pages
Line 318 in /xxxxx/xxxxx/cms/code/CommentAdmin.php

Cheers in advance

Avatar
frankmullenger

Forum Moderator, 53 Posts

5 March 2013 at 10:32am

You probably need to add a parameter to your CommentAdmin::EditForm() declaration so it matches:
https://github.com/silverstripe/sapphire/blob/3.0/admin/code/LeftAndMain.php#L1003

So, adding $request=null should do it.

Avatar
Willr

Forum Moderator, 5513 Posts

5 March 2013 at 5:18pm

Comments module has probably been kept up to date in align with 3.1 so try downloading the new 3.1 beta. You should use that or 3.0.5.

Avatar
Parker1090

Community Member, 38 Posts

8 March 2013 at 1:26am

Edited: 08/03/2013 1:28am

Thanks both for the reply.

I've updated the files to the 3.0.5 version, but it still throws an error as it's trying to look for a file that don't exist...

[Warning] require_once(/public_html/cms/code/CommentAdmin.php): failed to open stream: No such file or directory
GET /admin/pages/edit/show/1
Line 82 in /public_html/framework/core/manifest/ClassLoader.php

Why would it be trying to look for the old file?

Trace

Trace
SS_ClassLoader::loadClass
ClassLoader.php:82
SS_ClassLoader->loadClass(CommentAdmin)
spl_autoload_call(CommentAdmin)
ReflectionClass->__construct(CommentAdmin)
CMSMenu.php:271
CMSMenu::get_cms_classes()
AdminRootController.php:40
AdminRootController::rules()
AdminRootController.php:83
AdminRootController->handleRequest(SS_HTTPRequest,DataModel)
Director.php:296
Director::handleRequest(SS_HTTPRequest,Session,DataModel)
Director.php:119
Director::direct(/admin/pages/edit/show/1,DataModel)
main.php:126

Avatar
copernican

Community Member, 189 Posts

13 March 2013 at 3:30am

Did you try doing a ?flush=all after updating the files?