elementor / static-html-output

Static HTML Output Plugin for WordPress
https://statichtmloutput.com
The Unlicense
124 stars 33 forks source link

Redirecting based on _wp_old_slug ? #181

Open joyously opened 3 years ago

joyously commented 3 years ago

Is there any code that processes the meta key _wp_old_slug? Perhaps it could be a simple HTML redirect (like refresh) or output for .htaccess.

leonstafford commented 3 years ago

Hi @joyously,

There's no redirection handling within this plugin. https://github.com/leonstafford/wp2static has support for redirect handling, but that will depend on where you're deploying to, as each static host may handle differently.

You mentioned .htaccess, so I assume that you want to host your static site on another Apache server?

I may get to redirect support in the future, but for now, I'd propose manually creating the redirect rules for the URLs you are aware of. You may be able to grab all the _wp_old_slug entries from the WordPress database to help if there's a lot.

If you want a smoother experience for redirects, I can recommend Strattic, the company I now work for, who have a complete end to end WordPress to static site hosting/publishing platform with redirect support. If you're interested in that, there's a free trial and our team's really nice at onboarding people.