RE: More RewriteRule issues ..

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> -----Original Message-----
> From: bearsfoot [mailto:adam.p.reynolds@xxxxxxxxx] 
> Sent: Tuesday, November 24, 2009 3:24 AM
> To: users@xxxxxxxxxxxxxxxx
> Subject:  More RewriteRule issues ..
> 
> 
> Hi,
> 
> I have the following rules in my .htaccess.
> 
> RewriteRule products/(.*)/ /index.php?view=products&brand=$1 [L]
> RewriteRule products/(.*)/(.*)/ 
> /index.php?view=productdetail&brand=$1&id=$2
> [L]
> 
> These are the urls the users see:
> http://www.mysite.com/products/product-name/ 
> http://www.mysite.com/products/product-name/1/ 
> 
> These are the pages the users see:
> http://www.mysite.com/index.php?view=products&brand=product-name
> http://www.mysite.com/index.php?view=productdetail&brand=produ
ct-name&id=1
> 
> 
> I want to add another rule rewrites the folowing url. 
> http://www.mysite.com/products/product-name/?filter=10
> 
> to
> 
> http://www.mysite.com/index.php?view=products&brand=product-na
me&filter=10
> 
> Can someone please show me how to implement this rule without 
> interferring
> with the existing second rule  ?

What did you try yourself already? What results did you get? What
problems did you encounter?

Rgds,
Owen Boyle
Disclaimer: Any disclaimer attached to this message may be ignored. 

Hint: A query-string is NOT part of the URL and so is not immediately
visible to a RewriteRule. For further details, check out:
http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html#rewriterule (and
read the grey box "what is matched?")
http://wiki.apache.org/httpd/RewriteQueryString


> 
> Thanks,
> Adam
> 
> 
> -- 
> View this message in context: 
> http://old.nabble.com/More-RewriteRule-issues-..-tp26489575p26
489575.html
> Sent from the Apache HTTP Server - Users mailing list archive 
> at Nabble.com.
> 
> 
> ---------------------------------------------------------------------
> The official User-To-User support forum of the Apache HTTP 
> Server Project.
> See <URL:http://httpd.apache.org/userslist.html> for more info.
> To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
>    "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
> For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx
> 
> 
 
This message is for the named person's use only. It may contain confidential, proprietary or legally privileged information. If you receive this message in error, please notify the sender urgently and then immediately delete the message and any copies of it from your system. Please also immediately destroy any hardcopies of the message. 
The sender's company reserves the right to monitor all e-mail communications through their networks.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx



[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux