LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices

Reply
 
Search this Thread
Old 12-04-2006, 06:32 PM   #1
hoho4rd
LQ Newbie
 
Registered: Dec 2006
Posts: 2

Rep: Reputation: 0
Including header file using HTML


Is it possible to include a header and footer file using HTML? I have my file as a .html and need to be able to include the HTML for the header and footer. Anyone know how I can do this?
___________________
Free Online games
MingleOn SEO Web Directory

Last edited by hoho4rd; 12-11-2006 at 09:03 AM.
 
Old 12-04-2006, 07:34 PM   #2
chrism01
Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.5, Centos 5.10
Posts: 16,261

Rep: Reputation: 2028Reputation: 2028Reputation: 2028Reputation: 2028Reputation: 2028Reputation: 2028Reputation: 2028Reputation: 2028Reputation: 2028Reputation: 2028Reputation: 2028
Try a Server Side Include (SSI): http://httpd.apache.org/docs/1.3/howto/ssi.html
 
Old 12-05-2006, 08:22 AM   #3
jlinkels
Senior Member
 
Registered: Oct 2003
Location: Bonaire
Distribution: Debian Lenny/Squeeze/Wheezy/Sid
Posts: 4,062

Rep: Reputation: 491Reputation: 491Reputation: 491Reputation: 491Reputation: 491
This is an interesting option. As a matter of fact I do have a website for which I would like to include headers & footers on each page, without having to edit each and every page if I add something to the header.

I am renting webspace at a commercial host. It is a Linux system, and it uses Apache, however I don't think I actually have access to the Apache config files. I just rent hosting space, no dedicated server or so. (doteasy.com)

Or is it usual with those commercial hosts that you have a personal config file somewhere? I never tried funny things, because usually I break something. Which is no problem on one of my own machines, but certainly on some remote machine.

jlinkels
 
Old 12-05-2006, 08:44 AM   #4
introuble
Member
 
Registered: Apr 2004
Distribution: Debian -unstable
Posts: 700

Rep: Reputation: 31
Ask your company if they have SSI enabled. Or PHP. (or others, but with those two I am personal acquainted)
 
Old 12-05-2006, 11:20 AM   #5
Wim Sturkenboom
Senior Member
 
Registered: Jan 2005
Location: Roodepoort, South Africa
Distribution: Slackware 10.1/10.2/12, Ubuntu 12.04, Crunchbang Statler
Posts: 3,786

Rep: Reputation: 282Reputation: 282Reputation: 282
Have a look at iframes ( http://www.w3.org/TR/html401/present...ml#edef-IFRAME ). I think they will do the trick.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Including the header file of a module in kernel code omkarlagu Linux - Newbie 0 02-05-2006 07:55 AM
Including header files and source files for classes Feenix Programming 8 09-28-2005 10:53 AM
html code and including html files Hockeyfan Programming 2 08-22-2005 05:11 PM
How to write Makefile in 2.6 for including header files in another dir ? ashbalu Programming 0 10-19-2004 03:45 PM
Difference between including a header file and 'class' declaration in C++ scoTtkIm Programming 1 09-09-2004 04:23 AM


All times are GMT -5. The time now is 09:53 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration