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.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

General Questions /

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

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

Total n00b question, but ...


Go to End


2 Posts   723 Views

Avatar
sam523

Community Member, 3 Posts

9 April 2013 at 9:16am

I'm new to SilverStripe — new job, first exposure to SilverStripe, etc. We're on 2.4.5 for now and just did some changes with our code repositories and I'm struggling to figure out an issue preventing me from viewing things locally and hoping somebody has experienced this and knows the fix ...

For starters, it's running on a CentOS 6.4 VM on VirtualBox that runs on a virtual network and pulls the web files from a mounted folder from the host. Fairly certain the setup there is not the issue — I've run other things with it successfully and I'm getting some feedback from the code.

Anyways, I'm getting a white screen of death, but when I break it down to get thee error, it goes to the manifest file, it requires a file advancedworkflow/_config.php which calls Object::add_extension. Now, when I just run the site from what is essentially localhost (I have an alias I use that's config'd in my hosts file, but same difference ... I hope?) and the .htaccess rewrites to run sapphire/main.php, I get the white screen. Like I said though, with my var_dumping to track the error, it was in the manifest, which I copied over from the tmp directory and ran it. Doing that threw a fatal "Class Object not found" error.

In $_CLASS_MANIFEST, 'object' => '/{{ ... path ... }}/sapphire/core/Object.php' is in the array. In that file, there's an Object class, but it's an abstract class. Part of my head-scratching brought me to the conclusion that it's an abstract class and calling a static method from an abstract class is a problem (I know you can't instantiate an abstract class ... I've never even thought of calling a static method from one, but I don't think abstract is the issue, otherwise class not found wouldn't be the error). I also know (think?) that class is part of the framework, so I'm not going to touch it.

Obviously, I don't know much about Silverstripe, so I'm not sure what's causing this, and I'm not sure what SilverStripe does to autoload beyond that $_CLASS_MANIFEST array.

If anybody has any ideas or suggestions I would GREATLY appreciate your feedback!

Thanks,
Sam

Avatar
martimiz

Forum Moderator, 1391 Posts

10 April 2013 at 4:50am

Hi sam523,

I'm sure I don't understand you completely, especially the bit where the local site pulls the files from a mounted folder on the host, but I'm triggered by you saying you copied the manifest from the tmp folder. So just to make sure:

The manifest is part of the intricate cache system that SilverStripe will create on each install. To create the cache, SilverStripe will look for a silverstripe-cache folder, and if that doesn't exist, divert to the tmp folder. You should never include the cache files in a copy of a site since it's custombuilt for just that install. just leave the folder empty and let SilverStripe recreate the cache.

You can flush the cache by adding a ?flush=1 or ?flush=all to your url, but I've seen that faltering on a copied cache.

But then again, maybe you knew all this :)

Martine