For the uninitiated (excluding the uninterested) Wordpress is the platform that I use to host this site. Its a comprehensive content management system that is really for a blog but also does static pages. The posts make up the blog posts or news and the pages make up the static parts. Ever since I started using it I always found that some if not all the themes tend to have either a fixed width or a variable width that can be set in either the CSS or by some front end gui that makes life easy.
The theme I use is fixed, it also has a sidebar. There are also grids and containers that are used to organise where things go on the site. Trouble is that if you alter one aspect for one page then you can mess up the whole page. Enter 'Conditional Tags'. These are supposed to simplify things and to a large extent they do, so its easy right? not a chance. I wanted to do a simple thing, have one width for my home page with a sidebar and a wider width for the rest of the pages without a sidebar.
First get rid of sidebar from pages template - Easy - delete < get sidebar > Done. That left me with a white space where the sidebar used to be.
Right then I need two headers one wide one and one narrow one. Thing is you can't have two files called header, but you can have two called header wide and header narrow. Replace all the code in the header.php file with
<?php
if (is_home()){
include(TEMPLATEPATH.'/header-normal.php');
}
else {
include(TEMPLATEPATH.'/header-wide.php');
}
?>
But oh how many times did I have to write this without getting syntax errors. let me tell you tons. I have no php skills, no programming skills at all really but I can follow instructions, or so I thought, well I did follow them but in loads of cases they were completely wrong. Not just in one place but all over the internet. Cut and paste to make a blog page? I think so. Loads of requests in forums for help becuase of the syntax error, yes? any of them answered? not many.
When you step into an alien world where there is a language barrier its easy to point at an orange and ask for it in a sort of grunt. Us Brits have been able to speak pretty much every language by speaking slowly and loudly in English so you can be understood. Trouble is that doesn't work on the internet. Is this retribution for our inability to speak another language or me getting cross with computers again?
Time I took a break from all this computer jiggery pokery and concentrated on finishing off my portable cobbwebb antenna
No comments:
Post a Comment