Having problem hiding PHP scripts with Apache's mod_rewrite.

From: Date: Mon, 10 Jul 2000 19:04:06 +0000
Subject: Having problem hiding PHP scripts with Apache's mod_rewrite.
Groups: php.general 
Request: Send a blank email to php-general+get-5785@lists.php.net to get a copy of this message
Hi everybody; I'm trying to hide a script name in a URL so that I can access information like this: http://www.myserver.com/folder_containing_php_script/category/subcategory/keyword So that, the Apache server actually goes to http://www.myserver.com/folder_containing_php_script/index.php and then my script (which works correctly), splits the remainder of the URL: /category/subcategory/keyword into variables ($category = 'category',$subcategory='subcategory',$keyword='keyword'). That all works fine, except that I can no longer get my Apache server (running under FreeBSD unix 4.0) to use the .htaccess file I put in this directory: folder_containing_php_script/.htaccess ...to rewrite the url, so someone always gets an error if they try to go to that (obviously) bogus url (there is of course no folder called category/subcategory/number). To make the script work, I have to type a url like this into my browser: http://www.myserver.com/folder_containing_php_script/index.php/category/subcategory/keyword ... and people can see the name of the php script in there. I don't want that!! Does someone know the answer to hiding it? Thanks, Adam

« previous php.general (#5785) next »