Error when using Elemental Theme as basis for new custom theme.

Permalink 1 user found helpful
I have followed the instructions found here (https://www.concrete5.org/documentation/how-tos/designers/how-to-copy-the-elemental-theme-to-use-as-a-base-for-new-themes/) explicitly.

I however cannot install the theme (named "development").

Here is the error message I receive on the Themes install page.

"The theme file page_theme.php does not defines the class Application\Theme\Development\PageTheme"

Any ideas? Thank you so much!

View Replies: View Best Answer
JohntheFish replied on at Permalink Best Answer Reply
JohntheFish
Have a look at 'Cloneamental' in the marketplace. It is designed to serve as an example of how to do this.
MasterAtreu replied on at Permalink Reply
Thank you. However, I figured it out. The namespace was missing a character...lol. Thank you though!
ThomasJ replied on at Permalink Reply
ThomasJ
I too am experiencing this same error but I see nothing wrong with my namespace declaration, "namespace Application\Theme\Minimal". The example theme is not available in the marketplace but I have double checked my page_theme.php with other themes for 5,7. The only variation that I can see is that the "use" statement on another theme had a leading slash on it, "use \Concrete\Core\Page\Theme\Theme;". Is this correct or should I leave the leading slash off? I have tried it both ways without success.
ThomasJ replied on at Permalink Reply
ThomasJ
I found my problem. I was looking so hard at the declarations and namespace structure that I didn't consider that the top of the php script was missing the "php" in <?php.
ob7dev replied on at Permalink Reply
ob7dev
If your php.ini file (server config) has php short tags set to On, then you can use

<?


instead of

<?php

For your opening tag.