Mindman
06-09-2005, 11:11 AM
Is there a global variable that contains the name of the file for the page currently being viewed? So I can report that name to scripts that include the current page. :D
|
Click to See Complete Forum and Search --> : Is there a global variable that contains the file name of the current page?? Mindman 06-09-2005, 11:11 AM Is there a global variable that contains the name of the file for the page currently being viewed? So I can report that name to scripts that include the current page. :D Bootsman123 06-09-2005, 11:39 AM $_SERVER['PHP_SELF']; http://nl3.php.net/manual/en/reserved.variables.php Mindman 06-09-2005, 12:02 PM Thanks! Ultimater 06-09-2005, 12:58 PM Wooah, You just hit two birds with one stone! Thanks Bootsman123! ShrineDesigns 06-10-2005, 02:50 PM you can use the predefined constant __FILE__ this holds the actual file path to the current document, example<?php // included into document echo __FILE__; ?><?php include('dummy.php'); echo '<br>'; echo __FILE__; ?> Ultimater 06-10-2005, 03:06 PM More Gold, thank you for that ShrineDesigns. :) webdeveloper.com
Copyright Internet.com Inc., All Rights Reserved. |