header.php & footer.php breaking in subpage

Permalink
Hi!

I´m new to C5 and I'm building a custom theme.
I created all the files needed and slipt the code into header, content and footer. I created an Elements folder in my theme and placed the two include files there: header.php and footer.php.
Default page runs flawless, calling the css and the includes just fine.
The probleme comes when I created a subpage using one of the themes page templates that I also coded. I get the following warning for the includes:


Warning: include(C:/xampp/htdocs/tecniomnia/themes/tecni/elements/footer.php) [function.include]: failed to open stream: No such file or directory in C:\xampp\htdocs\tecniomnia\concrete\libraries\view.php on line 345

Warning: include() [function.include]: Failed opening 'C:/xampp/htdocs/tecniomnia/themes/tecni/elements/footer.php' for inclusion (include_path='C:/xampp/htdocs/tecniomnia/libraries/3rdparty;C:\xampp\htdocs\tecniomnia\concrete\config/../libraries/3rdparty;.;C:\xampp\php\PEAR') in C:\xampp\htdocs\tecniomnia\concrete\libraries\view.php on line 345

I'm a designer with a a medium level of developing skills but have no clue on how to solve this.

I have look all the forums but I can't find anything helpful.

Can anyone give me a hint, would be much appreciated

Thanks in advance.

Rei

catirebcn
 
Mainio replied on at Permalink Reply
Mainio
Sounds a lot like you have everything correctly.

I would personally check for typos in the include functions. I would suggest copying the include from the template that works to the one that doesn't.

I cannot think of anything else, it seems that you are calling them correctly...

Antti / Mainio
Mnkras replied on at Permalink Reply
Mnkras
could you post your default.php/view.php/other
catirebcn replied on at Permalink Reply
catirebcn
Thanks Mnkras!!

Problem already solved.

Cheers

Rei
catirebcn replied on at Permalink Reply
catirebcn
Thanks for the fast reply

I have already solved this problem.
Looking at the source code I found out that the includes were being called badly. I don't know what happened exactly but I erased the elements folder and created again the header and footer.
With that I got no warning messages.

I also want to share for newbies as me what I learned today:
Using the code suggested by C5(getStylesheet)for style-sheets broke my styles. As soon as I changed to getThemePath instead everything came to life.

So, if you're having problems with your styles check that you're using
<?php echo $this->getThemePath(); ?>/


Thanks for the fast reply

It's all beginning to make sense and I'm liking C5 a lot.

Cheers

Rei