Jump to:

23360 Posts in 18124 Topics by 2862 members

General Questions

SilverStripe Forums » General Questions » error accessing admin after trying to update

General questions about getting started with SilverStripe that don't fit in any of the categories above.

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

Page: 1
Go to End
Author Topic: 1752 Views
  • pjssms
    Avatar
    Community Member
    49 Posts

    error accessing admin after trying to update Link to this post

    hello,

    I have tried to update silverstripe but it failled and i reverted to the old version.

    After turning a detailed error i am getting this:
    [User Error] Bad class to singleton() - UserDefinedForm
    GET /admin

    Line 261 in /home/psantos/public_html/sapphire/core/Core.php
    Source

    252 *
    253 * @param string $className
    254 * @return Object
    255 */
    256 function singleton($className) {
    257    global $_SINGLETONS;
    258    if(!isset($className)) user_error("singleton() Called without a class", E_USER_ERROR);
    259    if(!is_string($className)) user_error("singleton() passed bad class_name: " . var_export($className,true), E_USER_ERROR);
    260    if(!isset($_SINGLETONS[$className])) {
    261     if(!class_exists($className)) user_error("Bad class to singleton() - $className", E_USER_ERROR);
    262       $_SINGLETONS[$className] = Object::strong_create($className,null, true);
    263       if(!$_SINGLETONS[$className]) user_error("singleton() Unknown class '$className'", E_USER_ERROR);
    264    }
    265    return $_SINGLETONS[$className];
    266 }
    267

    Trace

    * Bad class to singleton() - UserDefinedForm
    Line 261 of Core.php
    * singleton(UserDefinedForm)
    Line 206 of SiteTree.php
    * SiteTree::page_type_classes()
    Line 312 of CMSMain.php
    * CMSMain->PageTypes()
    Line 976 of CMSMain.php
    * CMSMain->AddPageOptionsForm()
    * call_user_func_array(Array,Array)
    Line 318 of ViewableData.php
    * ViewableData->obj(AddPageOptionsForm)
    Line 44 of .cache.home.psantos.public_html.cms.templates.Includes.CMSMain_left.ss
    * include(/tmp/silverstripe-cache-home-psantos-public_html/.cache.home.psantos.public_html.cms.templates.Includes.CMSMain_left.ss)
    Line 354 of SSViewer.php
    * SSViewer->process(CMSMain)
    Line 773 of ViewableData.php
    * ViewableData->renderWith(Array)
    Line 480 of LeftAndMain.php
    * LeftAndMain->Left()
    * call_user_func_array(Array,Array)
    Line 408 of ViewableData.php
    * ViewableData->XML_val(Left,,1)
    Line 59 of .cache.home.psantos.public_html.cms.templates.LeftAndMain.ss
    * include(/tmp/silverstripe-cache-home-psantos-public_html/.cache.home.psantos.public_html.cms.templates.LeftAndMain.ss)
    Line 354 of SSViewer.php
    * SSViewer->process(CMSMain)
    Line 175 of Controller.php
    * Controller->handleAction(HTTPRequest)
    Line 129 of RequestHandler.php
    * RequestHandler->handleRequest(HTTPRequest)
    Line 122 of Controller.php
    * Controller->handleRequest(HTTPRequest)
    Line 277 of Director.php
    * Director::handleRequest(HTTPRequest,Session)
    Line 121 of Director.php
    * Director::direct(/admin)
    Line 118 of main.php

    How can i fix this or how can i upgrade silverstripe ?

  • Willr
    Avatar
    Forum Moderator
    5483 Posts

    Re: error accessing admin after trying to update Link to this post

    UserForms has been separated into a module instead of being in the core. If you are using the functionality of a user defined form then you will need to download that module from http://silverstripe.org/user-forms-module/

  • pjssms
    Avatar
    Community Member
    49 Posts

    Re: error accessing admin after trying to update Link to this post

    I don´t think i am using it but i will try to follow what you say

    1752 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.