NYCPHP Meetup

NYPHP.org

[nycphp-talk] Who include()'d me?

Nunez, Eddy enunez at tiaa-cref.org
Thu Jul 31 16:16:10 EDT 2003


Err...Correction: $_SERVER[SCRIPT_FILENAME]

-----Original Message-----
From: Nunez, Eddy 
Sent: Thursday, July 31, 2003 4:15 PM
To: 'NYPHP Talk'
Subject: RE: [nycphp-talk] Who include()'d me?



Thanks! Should have thought of that...
I've used $PHP_SELF countless of times before.
I noticed I could also use $_SERVER[SCRIPT_NAME] for absolute path
to the "includer".

-Eddy

-----Original Message-----
From: Sexton, David [mailto:David.SextonJr at ubs.com]
Sent: Thursday, July 31, 2003 3:59 PM
To: 'NYPHP Talk'
Subject: RE: [nycphp-talk] Who include()'d me?


I believe you can use $_SERVER['PHP_SELF'] within the included file and it
will return the path/name of the includer file.

-----Original Message-----
From: Nunez, Eddy [mailto:enunez at tiaa-cref.org]
Sent: Thursday, July 31, 2003 3:53 PM
To: talk at lists.nyphp.org
Subject: [nycphp-talk] Who include()'d me?


 
Quick question:
Anyone know if there is a constant or something that contains the name
of the file that "I" was included into.
 
e.g.
 
includer.php:
<? include("codefile.inc");
    etc etc etc;
?>
 
codefile.inc:
<?
    [declare some functions, resolve world hunger, etc...]
   [but how do I figure out that I was used by "includer.php"?]
?>

 
I know about _FILE_, if I use it, it'll just return who the current file is
...
and no I don't want to pass it as an argument. Looking for something more
elegant.
 
Let me know if I am not making sense. Thanks.
 
-Eddy


**************************************************************
This message, including any attachments, contains confidential information
intended for a specific individual and purpose, and is protected by law. If
you are not the intended recipient, please contact sender immediately by
reply e-mail and destroy all copies. You are hereby notified that any
disclosure, copying, or distribution of this message, or the taking of any
action based on it, is strictly prohibited.
TIAA-CREF
**************************************************************




Please do not transmit orders or instructions regarding a UBS account by
email. The information provided in this email or any attachments is not an
official transaction confirmation or account statement. For your protection,
do not include account numbers, Social Security numbers, credit card
numbers, passwords or other non-public information in your email. Because
the information contained in this message may be privileged, confidential,
proprietary or otherwise protected from disclosure, please notify us
immediately by replying to this message and deleting it from your computer
if you have received this communication in error.  Thank you.

UBS Financial Services Inc.
UBS International Inc.

_______________________________________________
talk mailing list
talk at lists.nyphp.org
http://lists.nyphp.org/mailman/listinfo/talk


**************************************************************
This message, including any attachments, contains confidential information
intended for a specific individual and purpose, and is protected by law.  If
you are not the intended recipient, please contact sender immediately by
reply e-mail and destroy all copies.  You are hereby notified that any
disclosure, copying, or distribution of this message, or the taking of any
action based on it, is strictly prohibited.
TIAA-CREF
**************************************************************

_______________________________________________
talk mailing list
talk at lists.nyphp.org
http://lists.nyphp.org/mailman/listinfo/talk


**************************************************************
This message, including any attachments, contains confidential information intended for a specific individual and purpose, and is protected by law.  If you are not the intended recipient, please contact sender immediately by reply e-mail and destroy all copies.  You are hereby notified that any disclosure, copying, or distribution of this message, or the taking of any action based on it, is strictly prohibited.
TIAA-CREF
**************************************************************




More information about the talk mailing list