Unless you have specifically configured the plugin to do this it does not sound like something it is doing. The plugin will always redirect the same regardless of user agent.
The likely cause is that something has been cached, or something else is performing the redirect.
-
This reply was modified 3 years, 2 months ago by
John Godley.
I understand and this is where we looked. Disabling the redirect in Redirection stops the redirect, enabling it starts the redirect again.
https://drive.google.com/file/d/1ui9agW33QAieOvINzuf4Ol7HdHKYpLHu/view?usp=share_link
I am forcing https in the redirect to ensure it goes to https. However, I still get the http redirection in the crawl.
https://drive.google.com/file/d/1hrwjaom8L_416GgEvkBqgMdMIeNSnCMh/view?usp=sharing
If I disable the redirect in redirection plugin then it stops redirecting… The only redirection that is happening to this URL is the Redirection Plugin.
Please see the images above, the first is my setting in Redirection Plugin, the second is the crawl that shows it is a 301 redirect to an http page…
Your regular expression looks very strange. Does that actually match?
The second screenshot is not Redirection.
It has 230 hits and in my chrome browser with default agent, the redirect performs as intended… it seems to be happening with the “Googlebot Smartphone” user-agent only right now. But this is the most important one, as it is pulling down our page rank due to multiple redirects.
You commented “The second screenshot is not Redirection.”, I’m not sure what you mean. Do you mean this is not the redirection plugin doing this, or do you mean that this is not a redirection happening on the URL?
You can simplify that to just being a plain redirect with the ‘ignore trailing slash’ option enabled. There is no need for it to be a regular expression.
I mean that Redirection is not performing the redirect.
Basically, anything with
rhode-island/?page=1
OR
/rhode-island\{any_other_page}\?page=1
Should all redirect back to the parent page
/rhode-island
Without the ?page parameter…
Can you explain more how to set this up to do the simple redirect with the “ignore trailing slash”? I’m not a regex expert or with the Redirection Plugin. If you could point me in the right direction that would be great. We have over 600 of these setup and I will need to update each of them individually or with a DB update.
If redirection is not performing that redirect, what else could be? When I disable this redirect in the Redirection Plugin, the redirect stops, the only redirect I see is from the plugin…
/rhode-island\{any_other_page}\?page=1
I don’t think it will match that. Your regex matches /rhode-island/?page=1 and /rhode-island?page=1. You can find more details of regular expressions here: https://redirection.me/support/redirect-regular-expressions/
If redirection is not performing that redirect, what else could be?
I couldn’t say. There is no code in Redirection to target the user agent you mentioned, and no one else has raised this as an issue. Redirection will always identify itself in the response, and your screenshot does not show that identification. The cause is probably something to do with Cloudflare and you may find that clearing the cache helps. You could also try temporarily disabling it to see if the problem goes away.
Right you are correct, this is the intended behavior. The issue is only that the redirect is going to http, instead of http. I just purged the cache on WP Engine and Cloudflare and still getting the same results. Tried disabling Cloudflare Caching and still the same result…
Any other ideas? This is the only location we have redirects setup/managed… in the Redirection Plugin
This is the redirect from Redirection:
HTTP/2 301
date: Wed, 08 Mar 2023 18:03:25 GMT
content-type: text/html; charset=UTF-8
location: https://55places.com/rhode-island
cf-ray: 7a4cfea6fd9571b4-LHR
cache-control: max-age=600, must-revalidate
expires: Wed, 11 Jan 1984 05:00:00 GMT
cf-cache-status: BYPASS
cf-apo-via: origin,qs
cf-edge-cache: cache,platform=wordpress
pragma: no-cache
x-cache: MISS
x-cache-group: normal
x-cacheable: non200
x-orig-cache-control: no-cache, must-revalidate, max-age=0
x-powered-by: WP Engine
x-redirect-by: redirection
server-timing: cf-q-config;dur=4.9999998736894e-06
report-to: {"endpoints":[{"url":"https:\/\/a.nel.cloudflare.com\/report\/v3?s=ArKc8gXRzaIma4PcJEDDHcW1Jhh0s%3D"}],"group":"cf-nel","max_age":604800}
nel: {"success_fraction":0,"report_to":"cf-nel","max_age":604800}
server: cloudflare
alt-svc: h3=":443"; ma=86400, h3-29=":443"; ma=86400
This is the one that is different:
HTTP/2 301
date: Wed, 08 Mar 2023 19:29:48 GMT
content-type: text/html
location: http://www.55places.com/rhode-island
cf-ray: 7a4d7d330fd675de-LHR
cf-cache-status: BYPASS
cf-apo-via: origin,qs
server-timing: cf-q-config;dur=6.9999987317715e-06
report-to: {"endpoints":[{"url":"https:\/\/a.nel.cloudflare.com\/report\/v3?s=giJ9k3RnsOPi4xXJ%2FzQ%2FA7OKLLBxc%3D"}],"group":"cf-nel","max_age":604800}
nel: {"success_fraction":0,"report_to":"cf-nel","max_age":604800}
server: cloudflare
alt-svc: h3=":443"; ma=86400, h3-29=":443"; ma=86400
You can see how different it is. I do not use Cloudflare and do not know how it works. You may want to talk to them for further help, or maybe even WP Engine.
To follow up, the same incorrect response is received even if the URL does not match. For example https://www.55places.com/rhode-island?page=1&v=1 does not match the redirect but returns the same http response. To me it seems like you have created a redirect somewhere else.