You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Ben Kochie
becca1275c
|
6 years ago | |
---|---|---|
.. | ||
.travis.yml | 6 years ago | |
LICENSE | 6 years ago | |
README.md | 6 years ago | |
xmlrpc.go | 6 years ago |
README.md
go-xmlrpc
xmlrpc interface for go
Usage
package main
import (
"github.com/mattn/go-xmlrpc"
"fmt"
"log"
)
func main() {
res, e := xmlrpc.Call(
"http://your-blog.example.com/xmlrpc.php",
"metaWeblog.getRecentPosts",
"blog-id",
"user-id",
"password",
10)
if e != nil {
log.Fatal(e)
}
for _, p := range res.(xmlrpc.Array) {
for k, v := range p.(xmlrpc.Struct) {
fmt.Printf("%s=%v\n", k, v)
}
fmt.Println()
}
}
Installation
$ go get github.com/mattn/go-xmlrpc
License
MIT
Author
Yasuhiro Matsumoto (a.k.a. mattn)