Simple Machines Community Forum

Customizing SMF => SMF Coding Discussion => Topic started by: AmaZulu on November 05, 2008, 02:37:13 PM

Title: Messing with index.template.php
Post by: AmaZulu on November 05, 2008, 02:37:13 PM
After using a re-coloured default theme for two years, I want to spread my wings and see if I can create my own template to use on a new version of my site.

Basically I want to have a 2 column layout, with a fixed left column for Navigation around the rest of my site and other stuff, and have the forum appear in the right column, which will be fluid width.

I've created my basic table-less CSS layout using #leftcolumn {position:absolute; width: 200px} and #centercolumn {position: fixed; right: 200px} as my main divs. This works with my static HTML pages no problem.

In my current index.template.php I have a 100% width header that contains all the information and navigation for the site, but for the new look I want to know where exactly I should echo my <div id="centercolumn"> opening and closing tags so that the whole forum is wrapped in that tag?

I've tried it at the logical places, which would be just within the <body> and </body> tags, but for some reason I don't get 100% width on the board index page. It seems to be about 748px wide and I'm buggered if I can figure out what I am doing wrong.

Am I totally on the wrong track?
Title: Re: Messing with index.template.php
Post by: ccbtimewiz on November 05, 2008, 05:00:22 PM
I don't really follow you. Could you attach the file so I could work with code?
Title: Re: Messing with index.template.php
Post by: AmaZulu on November 06, 2008, 12:02:40 AM
Okay, do you want me to attach the current index.template.php file and my layout template?

Is there any way I can PM you?
Title: Re: Messing with index.template.php
Post by: AmaZulu on November 06, 2008, 12:02:47 PM
Not to worry, I eventually figured out what the problem was: bad CSS on my part. I got it looking the way I want it now.

This is fun - I am learning a tremendous amount about PHP, CSS and HTML just by creating my own theme.