Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Cherokee: users

Hiding Extensions

 

 

Cherokee users RSS feed   Index | Next | Previous | View Threaded


josh.trier at gmail

Feb 4, 2010, 3:09 PM

Post #1 of 3 (275 views)
Permalink
Hiding Extensions

Hello

Is there anyway to serve a file without using the extension? Example:
search?q=data&var2=data2, where search.php would reside in document root.
Currently it gives a 404. Apache2 handles this with mod_alias and lighttpd
has mod_magnet for this.

I'm assuming you have to use rewrites, but I can not get this to work. I got
as far as getting the page to load, but variables do not follow..

Thanks


reidrac at usebox

Feb 5, 2010, 10:06 AM

Post #2 of 3 (240 views)
Permalink
Re: Hiding Extensions [In reply to]

Hello,

El jue, 04-02-2010 a las 18:09 -0500, Josh Trier escribió:
> Hello
>
>
> Is there anyway to serve a file without using the extension? Example:
> search?q=data&var2=data2, where search.php would reside in document
> root. Currently it gives a 404. Apache2 handles this with mod_alias
> and lighttpd has mod_magnet for this.
>
>
> I'm assuming you have to use rewrites, but I can not get this to work.
> I got as far as getting the page to load, but variables do not
> follow..

You're right, you can use a regex rule, ie. /search.* with the handler
type internal with regex /search(.*)$ and
substitution /whatever_search.php$1

I suppose you have to be careful with this regex rule not interfering
the php extension rule (/search.php matches /search.*).

I guess /whatever_search.php would still be accessible, I don't know if
you can avoid it by means of the internal redirection.

Regards,

Juanjo

--
jjm's home: http://www.usebox.net/jjm/
blackshell: http://blackshell.usebox.net/
ramble on: http://rambleon.usebox.net/


_______________________________________________
Cherokee mailing list
Cherokee [at] lists
http://lists.octality.com/listinfo/cherokee


alvaro at octality

Feb 7, 2010, 2:29 PM

Post #3 of 3 (239 views)
Permalink
Re: Hiding Extensions [In reply to]

On 05/02/2010, at 00:09, Josh Trier wrote:

> Is there anyway to serve a file without using the extension? Example: search?q=data&var2=data2, where search.php would reside in document root. Currently it gives a 404. Apache2 handles this with mod_alias and lighttpd has mod_magnet for this.
>
> I'm assuming you have to use rewrites, but I can not get this to work. I got as far as getting the page to load, but variables do not follow..

There is nothing right now, although it looks like something we could implement fairly easily.
Could you please log a RFE for it? (at http://bugs.cherokee-project.com/)

Cheers!

--
Octality
http://www.octality.com/

_______________________________________________
Cherokee mailing list
Cherokee [at] lists
http://lists.octality.com/listinfo/cherokee

Cherokee users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.