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

SOLVED - Site content tree disappeared


Go to End


7 Posts   2242 Views

Avatar
jonchamberlain

Community Member, 5 Posts

14 March 2010 at 10:21pm

Edited: 22/03/2010 11:57pm

Hi,

I have a site (www.successfulspeaking.co.nz) which has been running quite happily on SS 2.0.1 for several years.

Anyway, was just working on some new pages in the CMS when all the the site content disappeared from the tree. All that is showing now is the 'Site Content' icon and 'page not found'. Thankfully, the live site seems to be unaffected (so I assume the db, template, content display functions are all still working).

So, I'm a bit confused as to what happened or how to restore the site - especially as there is nothing in the history tab either.

Help?

Cheers,
Jon

Avatar
Sean

Forum Moderator, 922 Posts

14 March 2010 at 11:28pm

Edited: 14/03/2010 11:29pm

You might want to consider upgrading to 2.3.6, since 2.0.1 is quite old! 2.4.0 is on the way too, so now could be the time.

Of course, you should upgrade and test locally in your dev environment with the live database first!

A few things to check with the existing site:

* Is the SiteTree table still containing all the data? SiteTree_Live should definitely have everything if the site's still showing pages
* Cross checking the ParentID columns of the pages in the SiteTree and SiteTree_Live - the top level pages should have a ParentID of 0

Sean

Avatar
jonchamberlain

Community Member, 5 Posts

15 March 2010 at 4:46am

Hi Sean,

Thanks for the reply. I guess it is about time we upgraded - I think I may wait for 2.4 if that's possible.

I have looked at the database, and as far as I can see, everything is where it should be in sitetree and sitetree_live. Just not showing up in the CMS.

Strangely enough, the only page in sitetree that has a parentid = 0 is the pagenotfound page. All the top level pages have a parentid = 1. Is this significant?

Cheers,
Jon

Avatar
Sean

Forum Moderator, 922 Posts

15 March 2010 at 9:06am

Edited: 15/03/2010 9:07am

That is, and this most likely explains why they don't show up in the CMS. Do the entries in SiteTree_Live have ParentID = 0? You could try backing up SiteTree, then copying the contents of SiteTree_Live into SiteTree. This could be a temporary fix before you decide to upgrade. :-)

Sean

Avatar
jonchamberlain

Community Member, 5 Posts

15 March 2010 at 9:49am

Hi Sean,

I looked through sitetree_live, and the only entries with parentid = 0 were the homepage and the error page. All the other top-level pages have a parentid=1, same as in sitetree.

Cheers
Jon

Avatar
jonchamberlain

Community Member, 5 Posts

17 March 2010 at 10:21am

*bump*

Avatar
jonchamberlain

Community Member, 5 Posts

22 March 2010 at 11:55pm

Hi Sean,

I found out what was causing the site to be not displayed in the CMS interface - turned out that the parentid of the home page was set to 31 instead 0. Since 31 in the id of a page in the site, I assume it set up some kind of circular reference which it couldn't resolve.

I was just about to copy sitetree_live into site tree and decided to do one final check of the data in those tables. When I found the problem, I took a backup and just overwrote the parentid of home page with 0 and the site was "magically" restored! Not sure how that could've happened, but I guess it may have been a stray click. Can the parentid of a page be set through the GUI?

Anyway, thanks for the suggestions. If nothing else, it has added to my knowledge of Silverstripe! ;-)

Cheers,
Jon