Closed Bug 988046 Opened 10 years ago Closed 9 years ago

Redirect /products/download.html to /firefox/new/#download-fx

Categories

(www.mozilla.org :: Pages & Content, defect)

Production
x86
macOS
defect
Not set
normal

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: cmore, Assigned: pmac)

References

(Blocks 1 open bug)

Details

(Whiteboard: [kb=1315511] )

Attachments

(1 file)

After bug 874913 is resolved and per comment https://bugzilla.mozilla.org/show_bug.cgi?id=874913#c6, we need to do the following steps:

Step 1: Redirect /products/download.html(and any query parameters) to stage #2 of /firefox/new

Step 2: Remove /products/download.html from SVN
Depends on: 874913
Whiteboard: [kb=1315511]
Fixed!

curl -I https://www.mozilla.org/en-US/products/download.html
HTTP/1.1 301 Moved Permanently
Server: Apache
X-Backend-Server: bedrock2.webapp.scl3.mozilla.com
Vary: Accept-Encoding
Content-Type: text/html; charset=iso-8859-1
Date: Thu, 04 Sep 2014 22:31:37 GMT
Location: https://www.mozilla.org/en-US/firefox/new/?#download-fx
Transfer-Encoding: chunked
Connection: Keep-Alive
X-Cache-Info: caching

Chriss-MacBook-Air:~ cmore$ curl -I https://www.mozilla.org/fr/products/download.html
HTTP/1.1 301 Moved Permanently
Server: Apache
X-Backend-Server: bedrock1.webapp.scl3.mozilla.com
Vary: Accept-Encoding
Content-Type: text/html; charset=iso-8859-1
Date: Thu, 04 Sep 2014 22:31:48 GMT
Location: https://www.mozilla.org/fr/firefox/new/?#download-fx
Transfer-Encoding: chunked
Connection: Keep-Alive
X-Cache-Info: caching
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Realized just now that this redirect is causing an issue with SEO on www.mozilla.org and for whatever reason, it has got much worse since October 2015.

I am getting 50k+ daily requests to URLs like this:

/en-US/firefox/new/?product=firefox-3.6.8&os=osx〈=en-US

For various different versions and operating systems and now Google is picking up that URL as the #1 way to download Firefox.

It appears all of this is because of the 301 redirect that was put in place is passing the parameters along to /firefox/new/ and Google is picking up those URLs as now separate URLs instead of the canonical URL of /firefox/new/.

See:

curl -I https://www.mozilla.org/en-US/products/download.html?test=cmore
HTTP/1.1 301 MOVED PERMANENTLY
Server: Apache
X-Backend-Server: bedrock1.webapp.scl3.mozilla.com
Vary: Accept-Encoding
Cache-Control: max-age=43200
Content-Type: text/html; charset=utf-8
Date: Thu, 12 Nov 2015 00:12:36 GMT
Location: https://www.mozilla.org/en-US/firefox/new/?test=cmore#download-fx
Expires: Thu, 12 Nov 2015 12:12:36 GMT
Transfer-Encoding: chunked
Connection: Keep-Alive
X-Robots-Tag: noodp
X-Frame-Options: DENY
Last-Modified: Thu, 12 Nov 2015 00:12:36 GMT
X-Cache-Info: caching

the test=cmore is being passed through the /firefox/new/ and since those parameters don't mean anything to /firefox/new/, SEO is getting messed up.

Example of how it should work:

https://www.mozilla.org/en-US/products/download.html?test=cmore 

should redirect to:

https://www.mozilla.org/en-US/firefox/new/

Let's also not even include the ?scene=2 or the #download-fx as that gets a big dangerous with cross-browser compatibility. 

So two things.

1) Remove passing parameters through the 301 redirect

2) Remove the #download-fx from the redirect on /firefox/new/
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
:pmac/jgmize: can you check this out?

It looks like this problem started May 2014 when we pushed this bug 1006616

See data here: http://cl.ly/image/0a1y2u2f0f1F

No idea why it got much worse Oct 2015.
Flags: needinfo?(pmac)
Flags: needinfo?(jmize)
I can take this.
Assignee: nobody → pmac
Flags: needinfo?(pmac)
Flags: needinfo?(jmize)
Commits pushed to master at https://github.com/mozilla/bedrock

https://github.com/mozilla/bedrock/commit/556ce432e8556037f910f7593ce04cea28431d63
Fix bug 988046: Remove query params from redirect.

For products/download.html.

https://github.com/mozilla/bedrock/commit/02c692ca3aff91f6d9d8cf1117a44d6e2e3826ca
Merge pull request #3543 from pmclanahan/fix-products-download.html-redirect-988046

Fix bug 988046: Remove query params from redirect.
Status: REOPENED → RESOLVED
Closed: 10 years ago9 years ago
Resolution: --- → FIXED
Verified url params are now being stripped in production:

$ curl -I "https://www.mozilla.org/en-US/products/download.html?foo=bar&baz=qux"
HTTP/1.1 301 MOVED PERMANENTLY
Server: Apache
X-Backend-Server: bedrock6.webapp.scl3.mozilla.com
Vary: Accept-Encoding
Cache-Control: max-age=43200
Content-Type: text/html; charset=utf-8
Date: Thu, 12 Nov 2015 01:31:04 GMT
Location: https://www.mozilla.org/en-US/firefox/new/
Expires: Thu, 12 Nov 2015 13:31:04 GMT
Transfer-Encoding: chunked
Connection: Keep-Alive
X-Robots-Tag: noodp
X-Frame-Options: DENY
Last-Modified: Thu, 12 Nov 2015 01:31:04 GMT
X-Cache-Info: caching
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: