logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Apache View previous topic :: View next topic
Reply to topic   Topic: Header
Author
Erwin



Joined: 06 May 2006
Posts: 16
Location: Alkmaar

PostPosted: Sat 06 May '06 17:03    Post subject: Header Reply with quote

How can I configure an header that is on every page and you can't shut it down?
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7294
Location: Germany, Next to Hamburg

PostPosted: Sat 06 May '06 17:40    Post subject: Reply with quote

If you are using PHP you can set a prepend file in PHP.ini
Back to top
Erwin



Joined: 06 May 2006
Posts: 16
Location: Alkmaar

PostPosted: Sat 06 May '06 18:12    Post subject: Reply with quote

Yes I use this:
Apache 2.2.2
PHP 5.1.4
MySQL 5.0.21
ImageMagick 6.2.7-2 Q8

How can I do that I am not that high with a server...
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7294
Location: Germany, Next to Hamburg

PostPosted: Sat 06 May '06 20:30    Post subject: Reply with quote

Find PHP.ini edit it with a text editor
find auto_prepend_file =

auto_prepend_file = C:/your/path/to/header.htm

if you using also html and htm files

Add

AddType application/x-httpd-php .htm .html

to your httpd.conf

don't forget to restart Apache.


Are you hosting pages for others or why do you want to add a header?
Back to top
Erwin



Joined: 06 May 2006
Posts: 16
Location: Alkmaar

PostPosted: Sat 06 May '06 22:19    Post subject: Reply with quote

I know, can I make a directory that isn't infected with this? I have a site with more that only this. (Well it will come)
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7294
Location: Germany, Next to Hamburg

PostPosted: Sun 07 May '06 14:10    Post subject: Reply with quote

Of cause you can put it in a htaccess file so only that directority and the sub folders would have the header. must be php_admin_flag [PHP directive name] [On|Off]
Back to top
Erwin



Joined: 06 May 2006
Posts: 16
Location: Alkmaar

PostPosted: Sun 07 May '06 16:51    Post subject: Reply with quote

I have an other problem now. The time isn't correct in apache how can I change it?
Back to top
James Blond
Moderator


Joined: 19 Jan 2006
Posts: 7294
Location: Germany, Next to Hamburg

PostPosted: Sun 07 May '06 19:46    Post subject: Reply with quote

Time isn't correct? Please explain it more. Normaly Apache and PHP takes the time from the PC itself.
Where is the wrong time displayed? In a PHP script? Elsewhere?
Back to top


Reply to topic   Topic: Header View previous topic :: View next topic
Post new topic   Forum Index -> Apache