This file contains 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
<?php | |
/* | |
* Template Name: Theme Custom | |
*/ | |
?> | |
<?php | |
if ( ! current_user_can( 'edit_theme_options' ) ) { | |
?><p>You doe not have access to custom this theme</p><?php | |
} else { | |
?><iframe src="http://local.wp34.com/wp-admin/customize.php" width="800" height="800"></iframe><?php |
This file contains 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
add_filter( 'query', 'mp_query_filter'); | |
function mp_query_filter($query) { | |
global $wpdb; | |
if ( preg_match( '/('. $wpdb->base_prefix .'mp_terms|'. $wpdb->base_prefix .'mp_term_relationships)/i', $query ) ) { | |
$query_after = str_replace($wpdb->base_prefix."mp_terms", $wpdb->base_prefix."terms", $query); | |
$query_after = str_replace($wpdb->base_prefix."mp_term_relationships", $wpdb->base_prefix."mp_term_relationships", $query_after); | |
// DEBUG START - This following is just for debug to check the output. This will write |
NewerOlder