Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. Global file in PHP

Global file in PHP

Scheduled Pinned Locked Moved Web Development
csharpphpasp-netcomquestion
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    Jassim Rahma
    wrote on last edited by
    #1

    Hi, What's the equalive to global file in PHP? I was using it in ASP.NET and I want to know if there is similar thing in PHP?

    Technology News @ www.JassimRahma.com

    M 1 Reply Last reply
    0
    • J Jassim Rahma

      Hi, What's the equalive to global file in PHP? I was using it in ASP.NET and I want to know if there is similar thing in PHP?

      Technology News @ www.JassimRahma.com

      M Offline
      M Offline
      MartyrsCry
      wrote on last edited by
      #2

      If you are referring to the global.asx file you find in most ASP.NET projects, then no, PHP doesn't work like the event driven setup that ASP.NET applications are. When a request comes in for a PHP file, that file is handed to the PHP interpreter which adds in any included files and then parses the file in memory. Just like if you were given a book and you were to read it line by line through the entire book. It then takes the response generated from interpreting the code and gives it back to the user. It does not fire events as it interprets. So there is no such thing as Application_BeginRequest or Application_Start calls. It just reads the file and generates a response. Hopefully that is what you mean. :)

      Looking for a programming project? Check out my book at http://www.coderslexicon.com/downloads/the-programmers-idea-book/

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups