Jump to content


Photo

PHP in httpd.conf?


  • Please log in to reply
2 replies to this topic

#1 steelmanronald06

steelmanronald06
  • Staff Alumni
  • Advanced Member
  • 2,004 posts
  • LocationOk

Posted 13 March 2006 - 09:17 PM

can I include a php file in apache by using:

include conf/monitor_apache.php

and if so, would that mean that the php file would exectue everytime someone went to any page on my website that is hosted through that apache server?

what I want to do is have a .php file that is included in just one place and have it execute on every page on my website without me going into each file on my server and doing and include '../includes/file.php';

#2 ToonMariner

ToonMariner
  • Members
  • PipPipPip
  • Advanced Member
  • 3,342 posts
  • LocationNewcastle upon Tyne, UK

Posted 13 March 2006 - 10:15 PM

you can set the auto prepend setting in your php.ini file.....
follow me on twitter @PHPsycho

#3 wildteen88

wildteen88
  • Staff Alumni
  • Advanced Member
  • 10,482 posts
  • LocationUK, Bournemouth

Posted 13 March 2006 - 10:18 PM

You might want to look at these settings in the php.ini file:
; Automatically add files before or after any PHP document.
auto_prepend_file =
auto_append_file =




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users