Skip to content

Commit

Permalink
Initial tests with wordpressxmlrpc.py
Browse files Browse the repository at this point in the history
  • Loading branch information
alexandre-mbm committed Jul 14, 2015
1 parent af16995 commit 94be7e1
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions paicemana/wordpressrxmlrpc.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
from wordpress_xmlrpc import Client
from wordpress_xmlrpc.methods import posts

client = Client(
'http://www.weeklyosm.eu/xmlrpc.php',
'alexandre', 'SENHA'
)

posts = client.call(posts.GetPosts())

#for post in posts[:1]:
#print(posts[1].id)
#print(posts[1].title)
#print(posts[1].link)
print(posts[0].content)

# http://python-wordpress-xmlrpc.readthedocs.org/en/latest
#
# http://codex.wordpress.org/XML-RPC_WordPress_API
# https://github.com/maxcutler/python-wordpress-xmlrpc/

0 comments on commit 94be7e1

Please sign in to comment.