Notices
Computer & Technology Related Post here for help and discussion of computing and related technology. Internet, TVs, phones, consoles, computers, tablets and any other gadgets.

PHP question

Thread Tools
 
Search this Thread
 
Old 04 June 2003, 10:41 AM
  #1  
gregh
Scooby Regular
Thread Starter
 
gregh's Avatar
 
Join Date: Dec 1999
Posts: 3,360
Likes: 0
Received 0 Likes on 0 Posts
Post

From within php can I find out what program has called another program?

I have a standard header.php file that I include in all my pages.

What I'd like to do is within header.php do:

if included from freeware.php or freereults.php then do one action else do another.

Is this possible?

regards,

greg
Old 04 June 2003, 11:10 AM
  #2  
Andrewza
Scooby Regular
 
Andrewza's Avatar
 
Join Date: Jan 2002
Posts: 667
Likes: 0
Received 0 Likes on 0 Posts
Post

check $_SERVER["PHP_SELF"] which will give you the name of the script running. I personally use this to tag ad banners for differrent pages.
Old 04 June 2003, 01:15 PM
  #3  
gregh
Scooby Regular
Thread Starter
 
gregh's Avatar
 
Join Date: Dec 1999
Posts: 3,360
Likes: 0
Received 0 Likes on 0 Posts
Post

cheers Andrew,

that's just what I want to use it for

greg
Related Topics
Thread
Thread Starter
Forum
Replies
Last Post
KAS35RSTI
Subaru
27
04 November 2021 07:12 PM
Brzoza
Engine Management and ECU Remapping
1
02 October 2015 05:26 PM



Quick Reply: PHP question



All times are GMT +1. The time now is 12:24 PM.