class Blogpost::Athera

Public Class Methods

post(opts={}) click to toggle source
# File lib/blogpost/athera.rb, line 3
def self.post(opts={})
  opts = Blogpost.options.merge(opts)
  host="http://a-thera.com/rpc"
  id = XMLRPC::Client.new2(host).call("blogger.getUsersBlogs", "", opts[:user], opts[:pass])[0]["blogid"]
  XMLRPC::Client.new2(host).call("metaWeblog.newPost", id, opts[:user], opts[:pass],
    {"title" => opts[:title],"description" => opts[:content]}, true)
end