Solved

Need to add query string to end of URL via Mod Rewrite

Posted on 2007-11-23
1
695 Views
Last Modified: 2008-02-01
I need to setup my .htaccess file with a rule that rewrites all visits to www.site.com/feed (with or without trailing slash) to www.site.com/feed?w=1

I've attached my current .htaccess contents below.



php_value memory_limit 128M
 

# BEGIN WordPress

<IfModule mod_rewrite.c>

RewriteEngine On

RewriteBase /

RewriteCond %{REQUEST_FILENAME} !-f

RewriteCond %{REQUEST_FILENAME} !-d

RewriteRule . /index.php [L]

</IfModule>

# END WordPress
 

AddHandler php5-script .php

Open in new window

0
Comment
Question by:stemwinder
1 Comment
 
LVL 43

Accepted Solution

by:
ravenpl earned 500 total points
ID: 20341985
Add
RewriteCond %{QUERY_STRING} !^w=1
RewriteRule ^feed$ feed?w=1 [L]
0

Featured Post

Free Gift Card with Acronis Backup Purchase!

Backup any data in any location: local and remote systems, physical and virtual servers, private and public clouds, Macs and PCs, tablets and mobile devices, & more! For limited time only, buy any Acronis backup products and get a FREE Amazon/Best Buy gift card worth up to $200!

Join & Write a Comment

"In order to have an organized way for empathy mapping, we rely on a psychological model and trying to model it in a simple way, so we will split the board to three section for each persona and a scenario and try to see what those personas would Do,…
Any business that wants to seriously grow needs to keep the needs and desires of an international audience of their websites in mind. Making a website friendly to international users isn’t prohibitively expensive and can provide an incredible return…
The viewer will learn how to count occurrences of each item in an array.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now