From owner-freebsd-isp Wed Apr 29 11:07:09 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id LAA26656 for freebsd-isp-outgoing; Wed, 29 Apr 1998 11:07:09 -0700 (PDT) (envelope-from owner-freebsd-isp@FreeBSD.ORG) Received: from marta.arcom.spb.su (marta.arcom.spb.su [195.190.100.18]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id LAA26640 for ; Wed, 29 Apr 1998 11:07:01 -0700 (PDT) (envelope-from snar@marta.arcom.spb.su) Received: (from snar@localhost) by marta.arcom.spb.su (8.8.5/t/97-Mar-14) id WAA14154; Wed, 29 Apr 1998 22:02:07 +0400 (MSD) Message-ID: <19980429220207.35806@nevalink.ru> Date: Wed, 29 Apr 1998 22:02:07 +0400 From: Alexandre Snarskii To: Stunt Pope Cc: Khetan Gajjar , freebsd-isp@FreeBSD.ORG Subject: Re: Adding footers automatically to served HTML pages References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.88 In-Reply-To: ; from Stunt Pope on Wed, Apr 29, 1998 at 10:44:18AM -0400 Sender: owner-freebsd-isp@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org On Wed, Apr 29, 1998 at 10:44:18AM -0400, Stunt Pope wrote: > > This isn't stricly a FreeBSD query, but I thought I might ask, > > since this is a list for ISP's - and someone here _must_ have > > done this before :-) > > > > Using Apache 1.2.6 on a 2.2.6-STABLE machine. > > > > I'd like to setup Apache to append a footer file to all HTML > > pages served by it. Any points on how to do this ? > > > > You could turn on SSI's (Server Side Includes) and then use > > > > at the bottom of all your pages. Personally I'd use something like > php3 (cause I'm biased) since you can do a lot more with it than > include footers. > > But SSI's is the easiest way. Check www.apache.org and run a search on > it. It's easiest way in case when you or your co-workers writes these pages. In the situation, where you're have no control on web-publish ( i.e. you allow your users to upload their pages via ftp ) but have a need to add a footer to any page on your server it's not easiest way :) Really easiesh way is: AddHandler footers .html Action footers /cgi-bin/footers.html in your srm.conf ( or httpd.conf, if you dont use srm ), where /cgi-bin/footers.html is _an executable_, like ---------------- cut here ------------------------ #!/bin/sh cat $PATH_TRANSLATED echo "
" echo "this page is hoted by best Internet Provider in this region of Earth" --------------- and there ------------------------ This script must be located in your ScriptAlias directory. PS: AddHandler contexts are: server config, virtual host, directory, .htaccess, so, if you have need to 'footify' only part of your server - you can do it easily. -- Alexandre Snarskii the source code is included To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-isp" in the body of the message