Re: PHP&Apache config to not require "?"
| From: | Jason Wong | Date: | Tue, 21 May 2002 17:03:40 +0000 |
| Subject: | Re: PHP&Apache config to not require "?" | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-98611@lists.php.net to get a copy of this message | ||
On Wednesday 22 May 2002 00:37, Timothy J. Luoma wrote:
> Hello PHP'ers
>
> I am currently using the very cool PHPSlideshow(1)
>
> This gives me URLs that look like this:
>
> http://www.tntluoma.com/show.php?directory=nursery/
>
> I would like to be able to have simpler URL like this:
>
> http://www.tntluoma.com/show/directory=nursery/
>
> I was researching for an answer for this and came across some information
> at http://www.evolt.org/article/rdf/18/22880/ that was quite
> helpful about
> Apache's 'force type' which means (I think) that I can use this:
>
> <FilesMatch "^show$">
> ForceType application/x-httpd-php
> </FilesMatch>
>
> that will mean that I do not have to use the .php, which is good.
Once you have forced
http://www.tntluoma.com/show
To run as your php script then ...
> But the question remains how I can drop the ? (originally found after the
> show.php? for a / as above)
... use $HTTP_SERVER_VARS['REQUEST_URI'] (or $_SERVER[...]) to grab and parse
the rest of the URL. Obviously you'll have to make some minor changes to
PHPSlideshow so that it will output the URL without the '?'
--
Jason Wong -> Gremlins Associates -> www.gremlins.com.hk
Open Source Software Systems Integrators
* Web Design & Hosting * Internet & Intranet Applications Development *
/*
Everybody gets free BORSCHT!
*/