Önce using CookComputing.XmlRpc eklenmeli.
public void wordpressPost()
{
blogInfo newBlogPost = default(blogInfo);
newBlogPost.title = "başlık";
newBlogPost.description = "konunun içeriği";
IgetCatList categories = (IgetCatList)XmlRpcProxyGen.Create(typeof(IgetCatList));
XmlRpcClientProtocol clientProtocol = (XmlRpcClientProtocol)categories;
string result = null;
result = "";
result = categories.NewPage(1,
"admin",
"şifren",
newBlogPost,
1);
}
public struct blogInfo
{
public string title;
public string description;
}
public interface IgetCatList
{
[CookComputing.XmlRpc.XmlRpcMethod("metaWeblog.newPost")]
string NewPage(int blogId, string strUserName,
string strPassword, blogInfo content, int publish);
}
Hiç yorum yok:
Yorum Gönder