Re: URL modification

From: Date: Sat, 23 Feb 2008 11:27:32 +0000
Subject: Re: URL modification
References: 1 2 3 4 5 6 7 8 9 10  Groups: php.general 
Request: Send a blank email to php-general+get-269943@lists.php.net to get a copy of this message
/rental/property/23425 to: /index.php?mod=property&section=rentals&propertyid=23425
Thinking about this a little, you still don't need mod_rewrite. "rental" could be a PHP script, forced through PHP with: <Files rental>
    ForceType application/x-httpd-php
</Files> In either a .htaccess file or, if performance is an absolute necessity, your httpd.conf file (ie .htaccess files are turned off). In your rental PHP script you simply look at the REQUEST_URI $_SERVER variable to determine the correct data to show. You could also forego the <Files> bit if you're willing to accept URLs like this: /rental.php/property/23425 -- Richard Heyes http://www.phpguru.org Free PHP and Javascript code

« previous php.general (#269943) next »