• Resolved michaelmartin73

    (@michaelmartin73)


    Hello John,

    I hope you’re well. Please excuse my ignorance about these matters, but I wanted to ask if it is possible to set a redirect as an http header in the site settings area of the plugin, specifically for www to non-www (the canonical option doesn’t seem to work consistently due to a caching issue with the host) on an ngnix server. I spoke to the host about this previously and they told me they added this to the config file:

    curl -I https://www.reclaimdesign.org
    HTTP/2 301
    server: nginx
    date: Thu, 27 Feb 2020 01:27:11 GMT
    content-type: text/html; charset=UTF-8
    content-length: 0
    location: https://reclaimdesign.org/

    I don’t have access to the config file, and the redirect is no longer working, and I’m over writing back and forward to the host, so I wondered if there was a way I could include the above info in an http header somehow? As I say, I’m not wise in the ways of redirect kung fu, so would appreciate your help.

    Michael.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author John Godley

    (@johnny5)

    Why doesn’t the canonical setting working consistently? It adds a header too, so is no different from any other method.

    Thread Starter michaelmartin73

    (@michaelmartin73)

    Hi John,

    I see. The host caching causes the canonical settings some problems. It works for a while, then it doesn’t until I manually clear the cache and it works for short while again.

    Plugin Author John Godley

    (@johnny5)

    I would find out more about why the cache behaves like that, as it doesn’t sound like it is working correctly.

    • This reply was modified 4 years, 7 months ago by John Godley.
    Thread Starter michaelmartin73

    (@michaelmartin73)

    I have tried on many occassions to find out how to resolve this with the host. They say they do not allow for permanent redirects because of the server setup:

    “It is technically not possible to add permanent settings to the Nginx configuration file due to the structure of the EasyWP service. The corresponding rule can be added, but it will be reset to the default state after some time.”

    In terms of caching they say it is not possible to adjust this other than clearing the cache manually as I am doing with the must-use EasyWP plugin that comes with my host pacakge.

    So I’ve been trying to find my own workaround, as I can’t afford to switch host now (and I paid up for a year).

    Plugin Author John Godley

    (@johnny5)

    I can’t say that makes a lot of sense. Every solution is essentially the same and if your host is going to keep reseting whatever you do then I don’t see a way around the problem.

    Thread Starter michaelmartin73

    (@michaelmartin73)

    It doesn’t make sense to me either. They say because it is a managed WP host it is the only way they can do it.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘HTTP Header Question (Site Settings)’ is closed to new replies.