5 replies [Last post]
barbs75
barbs75's picture
User offline. Last seen 30 weeks 2 days ago. Offline
rank Regular
Regular
Joined: 2007-09-12
Posts: 45
Points: 2

Hey, this is probably a really simple question to answer, but, i am creating a website, where on my index page, i have a top logo bar, underneath a top menu, and at the bottom a content bar with links and copyright logo. What i want, is for when a user to click to go to a page, for the content of the page to have the top logo, menu and bottom content to appear automatically on the page, and for the content bar to move up and down according to the content above it.....Can you do this with CSS? or do i have to literally but the toplogo, menu bar etc physically on all my pages and position the content bar on each page?!?i'm sure there is a more efficient and productive way of doing this...oh and i dont want to use a frameset...or this a good way to go? because they affect your SEO rating and stuff...

I really hope someone can help or suggest something, because i have lookeed everywhere for help on this and haven't been successful as of yet!

i will attach my index page and CSS so you can see what i mean more clearly

Cheers

Craig (Barbs75) Smile

AttachmentSize
index.html6.8 KB
CSS Style1.txt9.81 KB
rmfred
rmfred's picture
User offline. Last seen 35 weeks 16 hours ago. Offline
rank Elder
Elder
Timezone: GMT-7
Joined: 2004-01-31
Posts: 1055
Points: 6

What you need is called

What you need is called "includes" search for server side includes, php includes, asp includes --- depending on what scripting language your host supports

www.powerbitwebdesign.com Powerbit your custom web design company

qube99
qube99's picture
User offline. Last seen 2 years 47 weeks ago. Offline
rank Regular
Regular
Timezone: GMT-7
Joined: 2007-09-11
Posts: 39
Points: 0

You might try using the

You might try using the OBJECT tag. This is used for embedding external things such as movies, Flash and even good old HTML pages. t's an HTML 4 spec but I'm not sure all browsers handle all data types real wel so you'll need to test it.

Warning: embed_me.html could not be embedded.

www.w3.org/TR/REC-html40/struct/objects.html#edef-OBJECT

Steve Strickland
Ecommerce-Retail.com

barbs75
barbs75's picture
User offline. Last seen 30 weeks 2 days ago. Offline
rank Regular
Regular
Joined: 2007-09-12
Posts: 45
Points: 2

php includes

Hey rmfred, thankyou very much for your post! i have been reading up on includes and SSI. I have been able to use php includes, as that is on my apache server, however, if i do that the page HAS to be php right? well i cant seem to add normal html to that, as i want to include other divs and stuff on the page in the main body.
I know you can use the SSI standard include, but you need to reconfigure Apache htaccess file, which i'm not really comfortable doin, and also cant actually find that particular configuration file :? , only the standard httpd.conf file.

What do you suggest is the best way to tackle this? help would be much appreciated!

Cheers for your assistance so far!

Craig

rmfred
rmfred's picture
User offline. Last seen 35 weeks 16 hours ago. Offline
rank Elder
Elder
Timezone: GMT-7
Joined: 2004-01-31
Posts: 1055
Points: 6

Craig; yes the page having

Craig; yes the page having the include needs to be a php page.
You can include html in a php page... just remember that what you're including should be bare bones... no doctype, body or html tags etc.
So you have a php page:
Your doctype - head title body tags etc... then where you want to "include your menu you would do something like this:



The menu.php page would only have your menu

Home
About Us

Does that help?

www.powerbitwebdesign.com Powerbit your custom web design company

barbs75
barbs75's picture
User offline. Last seen 30 weeks 2 days ago. Offline
rank Regular
Regular
Joined: 2007-09-12
Posts: 45
Points: 2

positioning items in includes

Hey rmfred, thanks for your reply, i have managed to add content to the php page now, which is good. The only question i need answering now, is, i want to be able to have my bottom contentbar move up and down depending on the content above it? do you know what i mean? so the content bar will always be at the bottom, but if the content between my menu and the content bar is small/large or whatever, the content bar will move accordingly, not stay in the same place.

Because the otehr problem i am having is that i have attached positioning to my content bar in my main style sheet, so when i put everything of the contentbar to the top of my include page "TopContent.html" it moves the bars in all my other pages, obviously i plan to replace the code in the body of these documents with an include, but how can i make the bar move accordingly as described above, i cant get my head round it!

Is it easy to do this?

Cheers

Craig (Barbs75) Smile