Click to See Complete Forum and Search --> : Prevent Browser From Displaying PHP Scrip_Name


Anon
11-05-2000, 02:56 AM
Whenever I tried to call a PHP file, my browser always change its URL to include the PHP Scrip_Name.

Example :
If I was to called a file from http://localhost/mydir/somefiles.php, and tried parse a php script from it, the browser will change it to ttp://localhost/php/php.exe/mydir/somefiles.php.

Is there a way to prevent it from displaying the /php/php.exe in the browser window?

BTW, I am running PHP, Apache and MySQL in Windows environment. Thanks!

Anon
11-05-2000, 04:46 AM
That happens if you run PHP as a CGI.

This doesn't happen if you run PHP as a module, and PHP 4.0.3 comes with a dll module you can use with Apache. I don't remember if previous versions of PHP had this.

You can also setup a simple script that deletes the php.exe part of it from the PHP_SELF variable (or any other built-in variable)

Anon
11-07-2000, 05:09 AM
Thanks for the info. Anyway, I'm still new at this and therefore need some pointers on how to configure PHP, either as a module or using an additional script to prevent the /php/php.exe from displaying in the browser.

I have just upgraded my PHP to PHP 4.03pl1 but I am not sure on how to install it as a module under Win98/ME. Could you provide me with a link or maybe tell me how I can do that? Thanks in advance for any help.