It’s getting worse.
Now the the french url : http://www.connetport.com/8ou does not work.
Please help !
found the “bug” …….
It is due to wpml …. in WP 3.0.3 with up to date wpml the thing is that the wp_query does not work at all.
wpml wants that we use icl_object_id however, in this case, we don’t know the exact type of post so it’s useless.
I have made a quick / dirty fix in the plugin
In the template_redirect function I’ve made the following changes :
Original
if (is_numeric($post_id))
{
global $wp_query;
$posts = new WP_Query("p=$post_id&post_type=any");
if ($posts->have_posts())
{
$posts->the_post();
$post = $posts->post;
if (!$this->settings["posts_enabled"] && $post->post_type == "post") return;
if (!$this->settings["pages_enabled"] && $post->post_type == "page") return;
if (!$this->settings["attachments_enabled"] && $post->post_type == "attachment") return;
status_header(200);
wp_redirect(get_permalink().$ga_tracking, $redirect);
exit();
}
}
Modified
if (is_numeric($post_id))
{
global $wp_query;
$posts = new WP_Query("p=$post_id&post_type=any");
$wpmlfix = get_permalink($post_id);
if ($posts->have_posts() | (isset($wpmlfix) && trim($wpmlfix)!=''))
{
$posts->the_post();
$post = $posts->post;
if (!$this->settings["posts_enabled"] && $post->post_type == "post") return;
if (!$this->settings["pages_enabled"] && $post->post_type == "page") return;
if (!$this->settings["attachments_enabled"] && $post->post_type == "attachment") return;
status_header(200);
wp_redirect($wpmlfix, $redirect);
exit();
}
}
normaly this change does not have no more impact than correct the wpml + twitter friendly links bug.
hopes that helps someone.