Is there a PHP version of a globals.asx?

Discussion in 'PHP' started by LineOfSight, Jan 11, 2007.

  1. #1
    Using .NET I can place a file in the root directory of a site that will be called every time a page on the site is called - so it can contain site wide application variables. Is there something similar for PHP?

    Thanks
     
    LineOfSight, Jan 11, 2007 IP
  2. rodney88

    rodney88 Guest

    Messages:
    480
    Likes Received:
    37
    Best Answers:
    0
    Trophy Points:
    0
    #2
    PHP will only include what you tell it to. You'd need to require / include it on every page.
     
    rodney88, Jan 11, 2007 IP
  3. krakjoe

    krakjoe Well-Known Member

    Messages:
    1,795
    Likes Received:
    141
    Best Answers:
    0
    Trophy Points:
    135
    #3
    lotta apps have a global.php that contains include / require statements and constructs classes you might want or makes functions available aswell as vars and anything else there in .... same sort of thing ....
     
    krakjoe, Jan 11, 2007 IP