Hi, Thanks Jonathan, I'll take another look at the server log and see if I find any clues.
On Jul 30, 3:15 pm, Jonathan Lundell <jlund...@pobox.com> wrote: > On Jul 30, 2009, at 5:33 AM, LB22 wrote: > > > > > > > Below is what I'm trying to achieve, followed by the rules I put in > > my .htaccess file. Could someone please tell me where I'm going wrong, > > and in which directory I need to put the .htaccess file? Mod_rewrite > > is definitely enabled, but is there anything else I need to check in > > my httpd.conf file? Thanks for the help :o) > > > I want to rewrite any requests like this: > > >http://thisis.mydomain.com/somevalue > > > To this: > > >http://thisis.mydomain.com/application/controller/function?somevariab... > > > --- > > > This is what I put in my .htaccess file: > > > Options +FollowSymLinks > > > RewriteEngine On > > > RewriteRule ^https?://thisis.mydomain.com/(([a-zA-Z0-9])+)?$ > > ^http://thisis.mydomain.com/application/controller/function? > > somevariable=$1 > > I'm no expert on this, but my impression is that .htaccess should be > somewhere between the directory that has your domain root and the base > directory of web2py (from your URLs, this looks like the same > directory). > > FWIW, when I set up a rewrite for mod_proxy and the welcome app, I > ended up with something like this: > > RewriteRule ^(welcome(/.*)?)$http://127.0.0.1:8666/$1[P] > > You don't want the [P], of course, and the other details will vary, > but note that my pattern does not include http://. > > Also, you don't want ^ in your replacement pattern. > > Looking at your server log can help with this, once you're rewriting > *something*. I started by rewriting ^.*$ to foo, and seeing what the > log had to say; that's how I noticed that I didn't want the http://. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "web2py-users" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~----------~----~----~----~------~----~------~--~---