Skip to content

Instantly share code, notes, and snippets.

@sueleybyte
Last active August 9, 2019 11:56
Show Gist options
  • Save sueleybyte/ee1cf8c7edd87c83e4e01bb30a8ee22c to your computer and use it in GitHub Desktop.
Save sueleybyte/ee1cf8c7edd87c83e4e01bb30a8ee22c to your computer and use it in GitHub Desktop.
Update Wordpress HTTP to HTTPS
-- Options
UPDATE wp_options SET option_value = REPLACE(option_value, "http", "https") WHERE option_name = "siteurl" OR option_name = "home" AND option_value NOT LIKE "https%";
-- Posts
UPDATE wp_posts SET guid = REPLACE(guid, "http", "https") WHERE guid NOT LIKE "https%";
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment