Re: Rewrite without redirect?

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

 



If there's no redirect, the script would run as if it received no QS, but any JS running in the browser and performing GA triggers would think the QS was there, and would report it as unique. Regardless of whether you make it work or not, this isn't likely to be a desirable situation.

On Fri, 7 Feb 2025 at 20:16, Dave Wreski <dwreski@xxxxxxxxxxxxxxxxxxx.invalid> wrote:

Hi,

I'd like to figure out how best to strip random query strings applied by external sites to our links like this:

https://linuxsecurity.com/features/top-6-vulnerability-scanning-tools?ZhdOK=VBKCrHPPeszbcJQ

The problem is that Google considers them unique URLs, which creates a duplicate content situation.

This rule matches, but just creates what appears to be an implicit 302 redirect without a 200:

RewriteCond %{REQUEST_URI}      ^/features/(.+)
RewriteRule ^           https://webstage.linuxsecurity.com/features/%1 [QSD]

I also tried [L,QSD] but that appears to be the same.

Is it possible to strip a query string from a URL without also redirecting it? I'm adding QSD to existing redirects where applicable, but this would just be for URLs that aren't currently being redirected.

dave





--
Adam "Sinus" Skawiński

[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