Reply
mod rewrite - frustrating issues !!!
Old 01-20-2009, 04:20 PM mod rewrite - frustrating issues !!!
Average Talker

Posts: 24
Location: Boston, MA
Trades: 0
Hi guys. I'm already using mod-rewrite for search engine friendly URLs, such as:

Code:
RewriteRule ^category/(.*)/ browsecats.php?cid=$1
Which basically means that browsecats.php?cid=20 now works as /category/20/

I'm running into issues when trying to use mod-rewrite for words and not just numbers as above. This is my setup:

Code:
RewriteRule ^profile/(.*)/ view_profile.php?sb_name=$1
(sb_name is the username). It appears to work on the surface, as all URLs appear as:

profile/username/

However whenever I click on the link it takes me to a URL loop and says it will 'never complete'. So in summary numbers work fine, words do not, why is this???? Any help appreciated as I'm pulling my hair out.
__________________
http://donricklin.blogspot.com
spunko2010 is offline
Reply With Quote
View Public Profile
 
 
When You Register, These Ads Go Away!
Old 01-26-2009, 06:41 AM Re: mod rewrite - frustrating issues !!!
Andy Pugh's Avatar
Extreme Talker

Posts: 186
Name: Andy
Location: N.Ireland
Trades: 0
Hi there, you could try the following :

Code:
RewriteRule ^profile/(.*[A-Za-z]+)$ /profile/$1/ [R]
RewriteRule ^profile/(.*[A-Za-z]+)/$ /view_profile.php?sb_name=$1
Regards,
Andy
Andy Pugh is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to mod rewrite - frustrating issues !!!
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML

 



Page generated in 0.11362 seconds with 13 queries