TalkPHP

TalkPHP (http://www.talkphp.com/forums.php)
-   Absolute Beginners (http://www.talkphp.com/absolute-beginners/)
-   -   mod_rewrite help (http://www.talkphp.com/absolute-beginners/4811-mod_rewrite-help.html)

Enfernikus 08-03-2009 03:06 PM

mod_rewrite help
 
So I think today is an off day, but I can't manage to write the current rule to make:
domain.com/profile/name.foo

picked up as:
domain.com/profile/?user=name.foo

So far I have this
Code:

RewriteEngine On
Options +FollowSymLinks
RewriteRule /re/profile/(.*)/$ /re/profile/?user=$1

It throws off a 500 error which I presume is it's way of telling me I have some sort of syntactical error

sketchMedia 08-03-2009 04:01 PM

Try this, seems to work:
Code:

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
Options +FollowSymLinks
RewriteRule re/profile/(.*)/?$ /re/profile/?user=$1


Enfernikus 08-03-2009 04:41 PM

No luck, hm, perhaps I should've been more detailed I'm working with Wordpress's .htaccess file

Code:


# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /re/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
#RewriteRule re/profile/(.*)/$ /re/profile/?user=$1
RewriteRule . /re/index.php [L]
</IfModule>

# END WordPress

When I put Options +FollowSymLinks, I get a 500 error.
Or the RewriteRules


All times are GMT. The time now is 05:26 AM.

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0