All content disappears upon activating a new theme

Permalink
Hi All,

I have recently taken over a project at work where I am refreshing an old concrete5 site and making it look prettier and adding new functionality.

I am testing a move from an inferior theme to the lovely Alpha theme (from the market place) and when I activate the Alpha theme, all my content disappears (hundreds's of pages)?

The content still remains in the database and re-appears if I switch back.

I have spoken to the author of the Apha theme (amazing support but this is way outside the scope of their support) and they have quite rightly pointed out that the old theme did not conform to the standards that most C5 devs adhere to these days.

One option was to update the new theme with the content block names of the old theme, but I don't really want to go down this route as maintaining theme updates will be a pain and also I would like to conform to standards :)

Can anyone offer any pointers on how to fix this, maybe updating some data in the database could work (the database looked very complicated when I looked at it though :( )?

Many thanks in advance!

Andy

 
mnakalay replied on at Permalink Best Answer Reply
mnakalay
Hello,
What is most likely happening is that those 2 themes have names their areas differently.
Say the old theme names the main area "content" and the new one named it "main" as it's supposed to be then anything you added to the area names content in the old them will simply not appear in the new one since there is no "content" area.

One solution would be to rename the new theme's area to the old ones'.
Not that good since you would have problems getting updates and if that designer is right, you would not follow best practices.

Another option is to go to the database and in the table "Areas" modify the name of your areas. You will need to know the cID (the page ID) of each page you need to modify. You can find that in the sitemap. and then for each area, change the handle to the new one.

Be careful though, if you're not sure what you're doing you could mess things up terrible.

Make sure you have a backup of your database before you do anything.
karnage replied on at Permalink Reply
Hi mnakalay,

Many thanks for the reply, I am going to give this ago :)
JohntheFish replied on at Permalink Reply
JohntheFish
A sepcific issue along the lines @mnakalay describes is that according to c5 theme standards, the core areas of a theme should be 'Main' and 'Sidebar', not 'main' and 'sidebar' (they are case sensitive).

So whether you modify a theme or hack the areas in the database, the best solution for the long term future of your site is whichever conforms closest to the standard.
karnage replied on at Permalink Reply
Indeed :) The old theme used "Content" and the new theme uses "Main".

So I am now just going through the database to amend them all to "Main" :)