Hi all,
Embarrassingly, I am new to PHP and stumped.
I have a live site I've recently started admining, and all works fine. The machines are Unix. At home, I'm trying to replicate the functionality, and all PHP works accept when I reference code at the top of an inc file.
The code at the top is -
if (strpos($SCRIPT_NAME, 'download')) {
$nav = "download";
$js_num = 3;
}
This should update an image based on a page -
<img src="/images/navigation/<? echo $nav; ?>all_off.gif" width="445" height="25" border="0" usemap="#<? echo $nav; ?>map"></a>
It fails. I have a similar situation with a sash that has page specific content and it works fine in the same page. My -
include("$DOCUMENT_ROOT/template/filename.inc");
works dandy also. Any ideas? Me thinks it has something to do with the line -
if (strpos($SCRIPT_NAME, 'download')) {
and the value of $SCRIPT_NAME, but I can't find it anywhere. Any idea where in apache/php4 for Win32 I would find where this value is set, or even on unix/apache/php? On the live servers which again are Unix/linux it knows when I visit /download/ to update inages/etc with the proper foldername value, but I can't for the life of me find it.
Any help you could throw my way would be a beautiful thing.
Happ new year.
Eric