Skip to content

Instantly share code, notes, and snippets.

@muzizongheng
Created July 18, 2013 06:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save muzizongheng/6027222 to your computer and use it in GitHub Desktop.
Save muzizongheng/6027222 to your computer and use it in GitHub Desktop.
ping blog by url
#ping search engine's ping service
# http://ping.baidu.com/ping/RPC2
# http://rpc.pingomatic.com/
# http://api.moreover.com/ping
# http://api.my.yahoo.com/rss/ping
# http://blogsearch.google.com/ping/RPC2
# http://ping.bitacoras.com
# http://ping.feedburner.com
# http://ping.syndic8.com/xmlrpc.php
# http://rpc.blogrolling.com/pinger/
# http://rpc.icerocket.com:10080/
# http://rpc.technorati.com/rpc/ping
# http://rpc.weblogs.com/RPC2
# http://topicexchange.com/RPC2
# http://www.blogdigger.com/RPC2
# http://www.blogoole.com/ping/
# http://www.popdex.com/addsite.php
# http://www.wasalive.com/ping/
# http://www.weblogues.com/RPC/
# http://blogping.unidatum.com/RPC2/
# http://www.xianguo.com/xmlrpc/ping.php
# http://www.zhuaxia.com/rpc/server.php
# http://blog.youdao.com/ping/RPC2
def pingBlog(self, url):
blogNewPostUrl = url
if url[0:7] != "http://":
blogNewPostUrl = self.blogNewPostUrl%url
print(blogNewPostUrl)
for u in self.pingServiceUrls:
try:
server = xmlrpc.client.ServerProxy(u)
response = server.weblogUpdates.extendedPing(self.blogName , self.blogUrl , blogNewPostUrl, self.blogRSS)
print(response)
except Exception as err:
print("ping ", u, " failed: ", err)
finally:
pass
@pnbmedia123
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment