Include Error on Windows 7/ Apache 2.2/ php5.4.12/ Concrete5.6.1
PermalinkI'm a newbie to Concrete5, but have a development background. Sadly not php though. I'm looking to use Concrete5 as a CMS editing tool for a new client of mine. I'm using my windows machine as a dev box. It's likely I will be deploying to *nix. Anyway, I've created a theme called upbeat and can create GlobalAreas and Areas without issue.
However, I'm now wanting to progress to breaking up templates into common elements. I've hit a hurdle at the first fence, and it looks like it might possibly be a Windows deployment bug, or a config error on my part.
I've created elements/header.php under my theme directory. I've gone to use
<? $this->inc('elements/header.php');?>
Warning: include(C:\Program Files (x86)\Apache Software Foundation\Apache2.2\htdocs\concrete5.6.1\concrete/themes/upbeat/elements/header.php)failed to open stream: Invalid argument in C:\Program Files (x86)\Apache Software Foundation\Apache2.2\htdocs\concrete5.6.1\concrete\core\libraries\view.php on line 449
As you can see, Concrete seems to be getting it's slashes in a muddle. It starts out with \ slashes and ends, from the concrete folder on, with / slashes. Additionally, it seems to be looking in concrete5.6.1/concrete/themes. My theme is in concrete5.6.1/themes.
If anyone can help, I would truly appreciate it.
All the best,
DarbsDev
I reinstalled concrete5, and the include function now works. Apologies. Thx for the tutorial links.
When looking for a theme, concrete starts looking in the core, then looks in a few other places. If it still doesn't find anything and the whole lot breaks, the error message is usually reports the first or last place it started looking (and not where you wanted somewhere in the middle).
So the chances are you have something slightly wrong in the path and, having failed to find it, c5 started looking elsewhere and gave up.
There is a great howto on themes by 12345J and Jordanlev
http://www.concrete5.org/documentation/how-tos/designers/making-a-t...
You may also find these useful
http://www.concrete5.org/documentation/how-tos/developers/change-th...
http://www.concrete5.org/documentation/how-tos/designers/common-the...
http://www.concrete5.org/documentation/how-tos/designers/modify-a-p...
Finally, Remo's theme book:
http://www.concrete5.org/about/blog/concrete5-sightings/new-book-cr...