…= explode(“blogspot.com”, $old_url); $q = “SELECT guid FROM $wpdb->posts LEFT JOIN $wpdb->postmeta “. “ON ($wpdb->posts.ID = $wpdb->postmeta.post_id) WHERE “. “$wpdb->postmeta.meta_key=’blogger_permalink’ AND “. “$wpdb->postmeta.meta_value=’$permalink[1]’”; $new_url = $wpdb->get_var($q)? $wpdb->get_var($q) : “/”; header…