Jump to:

1156 Posts in 2568 Topics by 408 members

Upgrading SilverStripe

SilverStripe Forums » Upgrading SilverStripe » Image_Uploader Issue Upgrading 2.3.1 -> 2.3.2

Ask questions about upgrading SilverStripe to the latest version.

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

Page: 1
Go to End
Author Topic: 1553 Views
  • Johnny
    Avatar
    Community Member
    34 Posts

    Image_Uploader Issue Upgrading 2.3.1 -> 2.3.2 Link to this post

    Hello!

    I have an issue upgrading 2.3.1 to 2.3.2. It only happens in the production site. I've uploaded the cms/, sapphire/ and jsparty/ folder on the remote machine and when I try to get to the image in the CMS, it doesn't work. The error is :

    [Notice] Undefined index: Image_Uploader
    GET /ss/images/iframe/Event/32/PostCard

    Line 157 in /home/bbcm/public_html/ss/sapphire/core/ClassInfo.php
    Source

    148    /**
    149     * @todo Improve documentation
    150     */
    151    static function ancestry($class, $onlyWithTables = false) {
    152       global $_ALL_CLASSES;
    153
    154       if(is_object($class)) $class = $class->class;
    155       else if(!is_string($class)) user_error("Bad class value " . var_export($class, true) . " passed to ClassInfo::ancestry()", E_USER_WARNING);
    156
    157       $items = $_ALL_CLASSES['parents'][$class];
    158       $items[$class] = $class;
    159       if($onlyWithTables) foreach($items as $item) {
    160          if(!DataObject::has_own_table($item)) unset($items[$item]);
    161       }
    162       return $items;
    163    }

    Trace

    * ClassInfo::ancestry(Image_Uploader)
    Line 451 of Object.php
    * Object->__construct()
    Line 74 of RequestHandler.php
    * RequestHandler->__construct()
    Line 274 of Director.php
    * Director::handleRequest(HTTPRequest,Session)
    Line 121 of Director.php
    * Director::direct(/images/iframe/Event/32/PostCard)
    Line 118 of main.php

    Anyone has an idea what's going on? FYI: It works on my local environment. Not in the remote production environment. Maybe some files haven't been copied by FTP.

    I also see there's a cache for ClassInfo. Where's this cache is located? Maybe I should prune it?

    Thanks,

    JP

  • Johnny
    Avatar
    Community Member
    34 Posts

    Re: Image_Uploader Issue Upgrading 2.3.1 -> 2.3.2 Link to this post

    Fixed :

    Anyone who has an undefined index error in ancestry method should clear the cache :

    <?

    system ('ls /tmp -l');
    system ('rm -vdfr /tmp/silverstripe-cache*');

    ?>

    1553 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.