0

I am helping a friend with her website mainteinance and there is some strange behaviour that I do not fully understand.

When you search for her site on google.com, and click on her main website, the website has a redirect to google.com. If I copy and paste the same hyperlink and type it directly on the browser, it works fine.

  • I have reviewed .htaccess and it seems to be fine
  • Also checked a curl and traceroute seem to be okey
  • Checked dns
  • Checked the google console and everything seems fine, except when opening the link in a new tab

Here is the search https://www.google.com/search?q=lara+padilla&rlz=1C5CHFA_enUS812US812&oq=lara+padi&aqs=chrome.0.69i59j69i57j0l3j69i61l3.1411j0j4&sourceid=chrome&ie=UTF-8 where you can find the broken link at "Sra. D el alter ego de Lara Padilla" (not working)

And here is the link from the search https://srad.wtf/ (working if you just copy paste)

I feel completely lost, so any help will be invaluable, thanks

jmrueda
  • 101
  • 2
  • 2
    I see this behavior only on the home page. It is probably a server misconfiguration. Please provide the relevant web server configuration. – Michael Hampton Oct 09 '20 at 00:02
  • There are two different .htaccess. Here is one under {www_public} https://pastebin.com/yJncCXrD and there is a second one in a subfolder called {www_public}/public https://pastebin.com/z3kKk3uN – jmrueda Oct 12 '20 at 08:43

1 Answers1

1

It's not just Google. The site appears to be 302 redirecting back to the HTTP Referer when performing the "language" redirect.

When requesting the document root only you appear to be performing a (unconditional?) language (302) redirect to /es_ES/. However, when the HTTP Referer header is passed then you are redirecting back to the full Referer instead!?

Regarding the link in the question... ServerFault has a referrer-policy: no-referrer policy on outbound links so no Referer header is sent and no erroneous redirect occurs.

Aside: Language redirects are generally a bad idea for SEO and user experience since they are notoriously prone to error. The site in question appears to be unconditionally redirecting to /es_ES/ (Spanish), despite there being other (more relevant for me) language version(s) available, eg. /en/ (English).

MrWhite
  • 12,647
  • 4
  • 29
  • 41