Windows Live Writer And WordPress Mu (WPMU)

I finally was able to add my blog on WPMU to windows live writer.  I searched and searched and searched and finally found the answer.

Change these lines in xmlrpc.php:

    foreach ( $blogs as $blog ) {
        $blog_id = $blog->userblog_id; 
        switch_to_blog($blog_id); 
        $is_admin = current_user_can(‘level_8’); 
        $struct[] = array(
            ‘isAdmin’  => $is_admin,
            ‘url’      => get_option(‘home’) . ‘/’,
            ‘blogid’   => $blog_id,
            ‘blogName’ => get_option(‘blogname’)
        );
    } 
  return array($struct);

To:

$req_url = ‘http://’ . $_SERVER[‘HTTP_HOST’] . $_SERVER[‘REQUEST_URI’]; foreach ( $blogs as $blog ) { $rpc_url = get_option(‘home’) . ‘/xmlrpc.php’; if( $rpc_url == $req_url ){ $blog_id = $blog->userblog_id; switch_to_blog($blog_id); $is_admin = current_user_can(‘level_8’); $struct = array( ‘isAdmin’ => $is_admin, ‘url’ => get_option(‘home’) . ‘/’, ‘blogid’ => $blog_id, ‘blogName’ => get_option(‘blogname’) ); break; } } if($struct){ return array($struct); }else{ return $this->error; }