Site setup using PHP and CSS

Tutorials

If you are new to PHP and CSS dont expect to understand this at first. Its a hard language to understand. But read my tutorial cafully, and i will try to explain it as simple and carfully as i can.

The first thing you need to do is create a page and name it css.css DO NOT PUT PHP ON THE END OF IT.

Then you need to paste this code into the css.css page you have just created.


Now create a new page and name it header.php (this will be your sidebar). Copy the code below and paste it into the header.php page you have just created.


Okay, now i will talk you through the code you have just pasted into your header.php page.
Where it says WEBSITE TITLE HERE this is where you put the title of your site, or your layout number, anything really.

Where it says <--LAYOUT IMAGE--> This is your main blend on your main page, just paste the URL of your main blend here.

The <--SIDEBAR--> is your sidebar (obviously) The width is how many pixels wide your sidebar is, where it says left;0 Top:300 this means how many pixels the sidebar is from the left and from the top, same goes with the <--LAYOUT IMAGE--> part too.

The h1 and h2 bits are like your tables, where you type on your sidebar, you could add your navigation and stats etc..

The last part of the code where it says <--CONTENT OF PAGE--> this is your main iframe, where the main content of your site will go. The width is the width of the iframe and left and top is the same as above.

Now you have finneshed editing this code.

Now make a new page and name it footer.php. This is going to be where the back and forward links will be. Paste the folowing code in the footer.php page you have just created.


You do not need to edit any of this page, unless you know what you are doing. If you are new to PHP then i think you should leave this page alone for now.

Now for last page you need to add, which is your index.php Your main page your visitors will come to when they open your site. This is where your blog goes. So make a page and name it index.php and paste this code into it.


You can add your blog to this page now! Or add your cutenews code, if you have already installed cutenews. Or what ever blogging system you want to use.

Now you are done!! Have a look at your website and see if you need to change any of the measurments to suit you, once you play around with the codes you will used to it, and start to understand.
Back | Forward