Problems, need help? Have a tip or advice? Post it here.
3 posts Page 1 of 1
Hi guys, I'm having an issue when I use <cms:pages masterpage> pointing one way to another AND try to install the cms from the scratch. Eg.:

I have an index.php file with a

Code: Select all
<cms:pages masterpage="banner.php" > ... </cms:pages>

And insite banner.php file I have

Code: Select all
<cms:pages masterpage="index.php" > ... </cms:pages>

When I try to install i from the scratch t always gives me a:

Code: Select all
// when I access banner.php
ERROR: Tag "pages": masterpage 'index.php' not found
// when I access index.php
ERROR: Tag "pages": masterpage 'banner.php' not found

so I can't generate the DB dynamically for the first time.

I worked around taking the dump of my first install and installing in another machine... but i'd like to know if is there any way to ignore the pages tag on the first time I execute the page, so it can create the DB correctly.
Hi,

Seems to be a Catch-22 situation :)

During the normal course of site development one is not likely to encounter this but, as you found out, it can happen when one tries to migrate completed site onto another database/server.

The recommended way of migrating completed sites is discussed here - http://docs.couchcms.com/miscellaneous/ ... erver.html

By using the above method you'll avoid such deadlocks.

If, however, for some reason you have to install all templates manually then following could be the ways to resolve the deadlock -
a. Temporarily remove the problem cms:pages block by surrounding it with <cms:ignore>..</cms:ignore> tags. Get the template registered and then revert to the original code.
b. Or make the 'masterpage' parameter something different e.g. 'masterpagex' which effectively would be ignored by Couch thus making it use the current template instead. Revert back once the template is installed.

Hope it helps.
Nice KK, I used exactly this solution :) just wanted to know if there was another way to do this. Maybe a querystring parameter to ignore the `<cms:page>` tag.
3 posts Page 1 of 1