<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Apache mod_rewrite: one RewriteCond to many RewriteRules</title>
	<atom:link href="http://my.galagzee.com/2009/02/11/mod_rewrite-one-rewritecond-to-many-rewriterules/feed/" rel="self" type="application/rss+xml" />
	<link>http://my.galagzee.com/2009/02/11/mod_rewrite-one-rewritecond-to-many-rewriterules/</link>
	<description>Tech in a Galagzee, Not So Far Away.</description>
	<lastBuildDate>Sat, 28 Jan 2012 21:43:14 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Jussi Sivonen</title>
		<link>http://my.galagzee.com/2009/02/11/mod_rewrite-one-rewritecond-to-many-rewriterules/comment-page-1/#comment-37900</link>
		<dc:creator>Jussi Sivonen</dc:creator>
		<pubDate>Tue, 26 Apr 2011 06:34:32 +0000</pubDate>
		<guid isPermaLink="false">http://my.galagzee.com/?p=172#comment-37900</guid>
		<description>Hot damn! This bit of rewrite voodoo made my day! I&#039;ve been looking for the same answer w/o any luck and this worked like a charm. Thanks a lot!</description>
		<content:encoded><![CDATA[<p>Hot damn! This bit of rewrite voodoo made my day! I&#8217;ve been looking for the same answer w/o any luck and this worked like a charm. Thanks a lot!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Toto</title>
		<link>http://my.galagzee.com/2009/02/11/mod_rewrite-one-rewritecond-to-many-rewriterules/comment-page-1/#comment-25060</link>
		<dc:creator>Toto</dc:creator>
		<pubDate>Mon, 02 Aug 2010 15:01:40 +0000</pubDate>
		<guid isPermaLink="false">http://my.galagzee.com/?p=172#comment-25060</guid>
		<description>Great solution, BUT - it seems that using this I can&#039;t access to the atoms defined in the RewriteCond with %1, %2, etc. :(</description>
		<content:encoded><![CDATA[<p>Great solution, BUT &#8211; it seems that using this I can&#8217;t access to the atoms defined in the RewriteCond with %1, %2, etc. <img src='http://my.galagzee.com/wp-includes/images/smilies/icon_sad.gif' alt=':(' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ville Walveranta</title>
		<link>http://my.galagzee.com/2009/02/11/mod_rewrite-one-rewritecond-to-many-rewriterules/comment-page-1/#comment-24723</link>
		<dc:creator>Ville Walveranta</dc:creator>
		<pubDate>Fri, 16 Jul 2010 21:00:11 +0000</pubDate>
		<guid isPermaLink="false">http://my.galagzee.com/?p=172#comment-24723</guid>
		<description>Sometimes the skip rule is written like so:

&lt;strong&gt;RewriteRule .? - [S=&lt;em&gt;n&lt;/em&gt;]&lt;/strong&gt;

That essentially takes care of the same thing as an asterisk, i.e. it allows &quot;nothing&quot; for the pattern which is likely the key issue in your configuration.  Your situation may occur when you&#039;re matching [with a RewriteRule] a URL without a path (e.g. http://www.somedomain.tld).  Since a period requires at least one character, a rule without a question mark (&quot;zero or one times&quot;) or an asterisk (&quot;zero to unlimited times&quot;) attribute would be skipped and so the rules immediately following would be executed.</description>
		<content:encoded><![CDATA[<p>Sometimes the skip rule is written like so:</p>
<p><strong>RewriteRule .? &#8211; [S=<em>n</em>]</strong></p>
<p>That essentially takes care of the same thing as an asterisk, i.e. it allows &#8220;nothing&#8221; for the pattern which is likely the key issue in your configuration.  Your situation may occur when you&#8217;re matching [with a RewriteRule] a URL without a path (e.g. <a href="http://www.somedomain.tld" rel="nofollow">http://www.somedomain.tld</a>).  Since a period requires at least one character, a rule without a question mark (&#8220;zero or one times&#8221;) or an asterisk (&#8220;zero to unlimited times&#8221;) attribute would be skipped and so the rules immediately following would be executed.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: szal</title>
		<link>http://my.galagzee.com/2009/02/11/mod_rewrite-one-rewritecond-to-many-rewriterules/comment-page-1/#comment-24592</link>
		<dc:creator>szal</dc:creator>
		<pubDate>Sun, 11 Jul 2010 21:58:35 +0000</pubDate>
		<guid isPermaLink="false">http://my.galagzee.com/?p=172#comment-24592</guid>
		<description>This worked great, except for

RewriteRule . - [S=x]

Instead, it must be

RewriteRule .* - [S=3]

I don&#039;t know if it worked for the above users, but for me, using just a period (.) resulted in the following RewriteRules being used, until I changed it to .*

Regards</description>
		<content:encoded><![CDATA[<p>This worked great, except for</p>
<p>RewriteRule . &#8211; [S=x]</p>
<p>Instead, it must be</p>
<p>RewriteRule .* &#8211; [S=3]</p>
<p>I don&#8217;t know if it worked for the above users, but for me, using just a period (.) resulted in the following RewriteRules being used, until I changed it to .*</p>
<p>Regards</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Eric</title>
		<link>http://my.galagzee.com/2009/02/11/mod_rewrite-one-rewritecond-to-many-rewriterules/comment-page-1/#comment-23896</link>
		<dc:creator>Eric</dc:creator>
		<pubDate>Mon, 21 Jun 2010 19:38:04 +0000</pubDate>
		<guid isPermaLink="false">http://my.galagzee.com/?p=172#comment-23896</guid>
		<description>Perfect!
Using this trick to rewrite PNG images to JPG/GIF alternatives for IE6 browsers.


RewriteCond %{HTTP_USER_AGENT} !MSIE\s+6
RewriteRule . - [S=4]
RewriteRule ^MAIN_logo\.(png&#124;gif)$ /images/MAIN_logo.jpg [NC,L,R]
RewriteRule ^MAIN_bg\.jpg$ /images/MAIN_bg_ie6.jpg [NC,L,R]
RewriteRule ^((MAIN_[cdm][^_]+&#124;icon&#124;logo&#124;SpryMenuBarCorner)_.*)\.png$ /images/$1.gif [NC,L,R]
RewriteRule ^(bg_gradient_.*)\.png$ /images/$1.jpg [NC,L,R]</description>
		<content:encoded><![CDATA[<p>Perfect!<br />
Using this trick to rewrite PNG images to JPG/GIF alternatives for IE6 browsers.</p>
<p>RewriteCond %{HTTP_USER_AGENT} !MSIE\s+6<br />
RewriteRule . &#8211; [S=4]<br />
RewriteRule ^MAIN_logo\.(png|gif)$ /images/MAIN_logo.jpg [NC,L,R]<br />
RewriteRule ^MAIN_bg\.jpg$ /images/MAIN_bg_ie6.jpg [NC,L,R]<br />
RewriteRule ^((MAIN_[cdm][^_]+|icon|logo|SpryMenuBarCorner)_.*)\.png$ /images/$1.gif [NC,L,R]<br />
RewriteRule ^(bg_gradient_.*)\.png$ /images/$1.jpg [NC,L,R]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Martin</title>
		<link>http://my.galagzee.com/2009/02/11/mod_rewrite-one-rewritecond-to-many-rewriterules/comment-page-1/#comment-22991</link>
		<dc:creator>Martin</dc:creator>
		<pubDate>Fri, 21 May 2010 14:19:13 +0000</pubDate>
		<guid isPermaLink="false">http://my.galagzee.com/?p=172#comment-22991</guid>
		<description>That&#039;s really very nice solution and i&#039;m gonna to use it on my website. Thanx a lot.</description>
		<content:encoded><![CDATA[<p>That&#8217;s really very nice solution and i&#8217;m gonna to use it on my website. Thanx a lot.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

