HI there,
I want to remove the actions added to wp_head by a plugin but only in certain circumstances.
Here is code that doesn't work:
if (is_single() && get_post_type() == 'tenant') {
$row = $wpdb->get_row("SELECT * FROM Events WHERE WP_ID='$post->ID'",ARRAY_A);
remove_action('wp-head',array($aiosp, 'wp_head'));
$seo_head = "<title>" . $row['Event'] . " | " . $row['Town'] .
" | Events in ". $row['Country'] . "</title>";
}