Created
September 1, 2015 09:29
-
-
Save remcotolsma/ef52298489aecae60231 to your computer and use it in GitHub Desktop.
WordPress query to update the page templates quickly after renaming page template file.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
UPDATE | |
wp_postmeta | |
SET | |
meta_value = 'page-templates/template-overview.php' | |
WHERE | |
meta_key = '_wp_page_template' | |
AND | |
meta_value = 'page-templates/template-overzicht.php' | |
; | |
UPDATE | |
wp_postmeta | |
SET | |
meta_value = 'page-templates/template-trips.php' | |
WHERE | |
meta_key = '_wp_page_template' | |
AND | |
meta_value = 'page-templates/template-reizen.php' | |
; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment