Monday, July 21, 2008

PHP and Web Design

1.Open Notepad and type the following as shown below

Save it as header.html




2.Create new file in your notepad and type the following

Save it as main.html





3. Create one more new file and type the following

Save it as footer.html




4. Next we link them together. Open another new file in your notepad

and type the following. This is how the linking in PHP done.

Save it as index.html. All pages should be in the same folder.

Otherwise the linking won't work. Now access the index.html through

your webserver. You should be able to see the following page.

Now change the contents of each page with respective content, I have

tried to make it as simple as possible and not to put so much codes inside

the html, so that you won't get confused. Because once you know how it

is done, you can replace the contents yourself with complicated codes

such as tables, javascript, CSS etc. So if you have 100 pages and you have

to change your Top Menu link, you don't have to go to every page and

change it manually, just change it in header.html and it is done! Good Luck!





No comments: