GetSimple Support Forum

Full Version: Innovation theme
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
In GetSimple's page editor, the user can select a non-template file as a template for a page (sidebar, header, footer), breaking the rendered page.

This problem happens (or would happen) with any theme that has several non-template .php files besides functions.php (which is excluded from the template dropdown).

(Possible fix: stuff everything in the template.php file)
I'm wondering if we can set a variable inside that template file (eg: footer.php) that will force it to now show itself in that dropdown...

I dont like that this can happen either...
Carlos Wrote:(Possible fix: stuff everything in the template.php file)

Carlos, that is not a fix, as it cuts down flexibility ... But I think, Chris' idea can be helpful , a variable that stops the "partial template" to be set as page-template
@ccagle8

Another option could be excluding/including files in the dropdown by name, doing one of these:

1. list everything but inc-*.php (and functions.php)
+ Rename non-template files to inc-sidebar.php, inc-header.php...
(alternatives: sidebar.inc.php, inc_sidebar.php, etc.)

2. list only template*.php files
+ If you use other template files besides template.php, you'd have to make sure their names begin with "template"
(alternatives: template-name.php, name-template.php, etc.)
I've gotten into the habit of naming included files with ".inc" rather than ".php"

Maybe we could just rename to this.
n00dles101 Wrote:I've gotten into the habit of naming included files with ".inc" rather than ".php"
Maybe we could just rename to this.

Some servers treat ".inc" as a text file, unless you configure to treat them as php files.

Maybe better ".inc.php" ...
i like the .inc.php check first... Great idea!
Done! that was a great idea everyone... when great minds get together we can create some pretty good fixes to obvious problems.

http://code.google.com/p/get-simple-cms/...tail?r=524
great idea, now I have to work on my theme ;=)

let's not forget to documentate that in the wiki when the version is out!
Connie Wrote:let's not forget to documentate that in the wiki when the version is out!
Im going to add it now, and just add (3.1+) beside it...