Never been to DZone Snippets before?

Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

Pinging site (See related posts)

Вот простой пример как пропинговывать сайты при новых постах без включения допоплнительных плагинов и модулей

irb(main):032:0>
irb(main):033:0* server = XMLRPC::Client.new("blogsearch.google.com", "/ping/RPC2", 80)
=> #<XMLRPC::Client:0x2aaaaeb222e8 @create=nil, @port=80, @http=#<Net::HTTP blogsearch.google.com:80 open=false>, @proxy_host=nil, @http_last_response=nil, @parser=nil, @timeout=30, @path="/ping/RPC2", @password=nil, @http_header_extra=nil, @use_ssl=false, @host="blogsearch.google.com", @user=nil, @proxy_port=nil, @auth=nil, @cookie=nil>
irb(main):034:0> server.call("weblogUpdates.extendedPing", 'Rubyclub.com.ua new on site','http://rubyclub.com.ua/', 'http://rubyclub.com.ua/messages/rss')
=> {"message"=>"Thanks for the ping.", "flerror"=>false}


You need to create an account or log in to post comments to this site.


Click here to browse all 5147 code snippets

Related Posts