New Package - Ping XMLRPC - UmbracoBlog addon Options
tim
Posted: Sunday, November 18, 2007 9:32:10 PM

Rank: Addict

Joined: 2/19/2007
Posts: 738
Location: Belgium
Ping multiple sites with this new addon.

Package:http://testing.netcentric.be/TG.Umb.PingXMLRPC/TG.Umb.PingXMLRPC_1.0_RC1.umb
Source:http://testing.netcentric.be/TG.Umb.PingXMLRPC/TG.Umb.PingXMLRPC.zip

The packages adds 2 new files.

/bin/TG.Umb.PingXMLRPC.dll
/umbraco/plugins/TG/PingXMLRPC/config.xml

Now everytime you publish a post a ping is send ( async ) to the different services listed in the config.xml file.

Code:

<?xml version="1.0"?>
<PingXMLRPC>
    <Settings>
        <Name></Name>
        <URL></URL>
    </Settings>
    <Services>    
        <Service>http://rpc.pingomatic.com</Service>
        <Service>http://pingoat.com/goat/RPC2/</Service>
        <Service>http://pingqueue.com/rpc/</Service>
        <Service>http://www.bloglines.com/ping</Service>
        <Service>http://blogsearch.google.com/ping/RPC2</Service>
        <Service>http://www.blogpeople.net/servlet/weblogUpdates</Service>
        <Service>http://bulkfeeds.net/rpc</Service>
        <Service>http://ping.myblog.jp</Service>
        <Service>http://ping.bitacoras.com</Service>
        <Service>http://ping.bloggers.jp/rpc/</Service>
        <Service>http://bblog.com/ping.php</Service>
    </Services>
</PingXMLRPC>


If Name and Url are not filled in then the Blog Name property and the url of the blog is used. Everything is logged so you can check the response.

If there is any interest I can update this package so it can be used it on other sites ( non umbracoblogs )

Cheers

Umbraco tips and tricks: http://www.nibble.be - umbraco mvp 08/09 - certified level 1 & 2 professional
tim
Posted: Sunday, November 18, 2007 9:33:59 PM

Rank: Addict

Joined: 2/19/2007
Posts: 738
Location: Belgium
http://testing.netcentric.be/TG.Umb.PingXMLRPC/TG.Umb.PingXMLRPC_1.0_RC1.umb

Umbraco tips and tricks: http://www.nibble.be - umbraco mvp 08/09 - certified level 1 & 2 professional
kalpa
Posted: Sunday, November 18, 2007 11:41:32 PM

Rank: Fanatic

Joined: 7/19/2006
Posts: 492
Location: Göteborg, Sweden


Tim Geyssens wrote:

If there is any interest I can update this package so it can be used it on other sites ( non umbracoblogs )
Cheers


Hi Tim!

Superb contribution to the growing flora of nice little Umbraco Helpers ; )

If you would like to make it a bit more versatile you could move some more properties out to the config XML, especially the "documentObject.ContentType.Alias" that's set to "umbracoBlogPost" for the moment... Then it could be used for any custom site...

Another (very cool) option might be to listen to the RSS package for fileupdates ; )

Anyway, great little addon this one! I'll use it as soon as it's a bit more generic ; )

// ; ) Kalle



" - Yeah I'd like to share your point of view, as long as it's my view too... (http://www.d-a-d.dk/lyrics/pointofview)
tim
Posted: Monday, November 19, 2007 9:39:09 AM

Rank: Addict

Joined: 2/19/2007
Posts: 738
Location: Belgium
Hi Kalle,

Thanks for the reply, sure I'll make it more generic, just didn't know if anyone would be interested.

Greets,

Tim

Umbraco tips and tricks: http://www.nibble.be - umbraco mvp 08/09 - certified level 1 & 2 professional
warren
Posted: Monday, November 19, 2007 10:07:32 AM

Rank: Addict

Joined: 7/19/2006
Posts: 777
Location: Leigh-on-Sea, Essex, UK
Hiya Tim,
Thanks for actually putting my idea into practice - when I get some time I will test this out.

I will be interested to know where logged responses are kept, so I can check the PING response has worked successfully.

Warren



Warren Buckley an Umbraco MVP 08-09 & level 1 certified developer
tim
Posted: Monday, November 19, 2007 10:22:44 AM

Rank: Addict

Joined: 2/19/2007
Posts: 738
Location: Belgium
Everything is logged in the umbracolog table

Code:


select * from umbracoLog where logComment like 'ping%'


Code:

Ping - Response - http://ping.bloggers.jp/rpc/ - <?xml version="1.0" encoding="UTF-8"?> <methodResponse> <params> <param> <value><struct> <member><name>flerror</name> <value><boolean>0</boolean></value> </member> <member><name>message</name> <value><string>Thanks for the ping.</string></value> </member> </struct></value> </param> </params> </methodResponse>


Haven't tested this but the logs should be visible with the log viewer
http://objects.dk/2006/6/5/log-viewer-updated.aspx

Umbraco tips and tricks: http://www.nibble.be - umbraco mvp 08/09 - certified level 1 & 2 professional
tim
Posted: Monday, November 19, 2007 3:12:39 PM

Rank: Addict

Joined: 2/19/2007
Posts: 738
Location: Belgium
Owkey I updated so it can be used on all document types ( not only umbracoblog )

Package: http://testing.netcentric.be/TG.Umb.PingXMLRPC/RC2/TG.Umb.PingXMLRPC_1.0_RC2.umb
Source: http://testing.netcentric.be/TG.Umb.PingXMLRPC/RC2/TG.Umb.PingXMLRPC.zip

It still only installs 2 files

/bin/TG.Umb.PingXMLRPC.dll
/umbraco/plugins/TG/PingXMLRPC/config.xml

Contents of config.xml:
Code:


<?xml version="1.0"?>
<PingXMLRPC>
    <Settings>
        <Name></Name>
        <URL></URL>
        <DocumentTypeAlias>umbracoBlogPost</DocumentTypeAlias>
        <ParentDocumentTypeAlias>umbracoBlog</ParentDocumentTypeAlias>
    </Settings>
    <Services>    
        <Service>http://rpc.pingomatic.com</Service>
        <Service>http://pingoat.com/goat/RPC2/</Service>
        <Service>http://pingqueue.com/rpc/</Service>
        <Service>http://www.bloglines.com/ping</Service>
        <Service>http://blogsearch.google.com/ping/RPC2</Service>
        <Service>http://www.blogpeople.net/servlet/weblogUpdates</Service>
        <Service>http://bulkfeeds.net/rpc</Service>
        <Service>http://ping.myblog.jp</Service>
        <Service>http://ping.bitacoras.com</Service>
        <Service>http://ping.bloggers.jp/rpc/</Service>
        <Service>http://bblog.com/ping.php</Service>
    </Services>
</PingXMLRPC>



So standard it is setup for use on the umbracoblog. If you want to use this for other documenttypes you need to modify

DocumentTypeAlias and ParentDocumentTypeAlias
DocumentTypeAlias is the alias of the documenttype wich will trigger the action ( on publish )
ParentDocumentTypeAlias is the alias of the documenttype of the parent node

So if you have:
-Homepage
--News (NewsAlias)
---Newsitem (NewsItemAlias)

And you want to ping when a newsitem is published
DocumentTypeAlias = NewsItemAlias
ParentDocumentTypeAlias = NewsAlias

The Url will autogenerate ( Niceurl of the parent document ). But you can override that by setting the url in the config.xml file.

And you will need to set a name in the config.xml file if this isn't used on the umbraco blog.

So An example:
Code:

<?xml version="1.0"?>
<PingXMLRPC>
    <Settings>
        <Name>My Comany's newsblog</Name>
        <URL></URL>
        <DocumentTypeAlias>NewsItemAlias</DocumentTypeAlias>
        <ParentDocumentTypeAlias>NewsAlias</ParentDocumentTypeAlias>
    </Settings>
    <Services>    
        <Service>http://rpc.pingomatic.com</Service>
        <Service>http://pingoat.com/goat/RPC2/</Service>
        <Service>http://pingqueue.com/rpc/</Service>
        <Service>http://www.bloglines.com/ping</Service>
        <Service>http://blogsearch.google.com/ping/RPC2</Service>
        <Service>http://www.blogpeople.net/servlet/weblogUpdates</Service>
        <Service>http://bulkfeeds.net/rpc</Service>
        <Service>http://ping.myblog.jp</Service>
        <Service>http://ping.bitacoras.com</Service>
        <Service>http://ping.bloggers.jp/rpc/</Service>
        <Service>http://bblog.com/ping.php</Service>
    </Services>
</PingXMLRPC>



I also provided a link to the source, so even if you don't use the package you can download the source and see an example on how to create actionhandlers for umbraco.

Cheers,
Tim




Umbraco tips and tricks: http://www.nibble.be - umbraco mvp 08/09 - certified level 1 & 2 professional
kalpa
Posted: Monday, November 19, 2007 8:31:35 PM

Rank: Fanatic

Joined: 7/19/2006
Posts: 492
Location: Göteborg, Sweden
Excellent Tim!

I will try this one in the next couple of days...

Thanks!

// ; ) Kalle

" - Yeah I'd like to share your point of view, as long as it's my view too... (http://www.d-a-d.dk/lyrics/pointofview)
sthurein
Posted: Monday, November 19, 2007 11:27:44 PM
Rank: Newbie

Joined: 7/12/2007
Posts: 7
Exellent work Tim!

I'll have to test this out later this week.

Cheers
S
tim
Posted: Sunday, December 02, 2007 6:52:20 PM

Rank: Addict

Joined: 2/19/2007
Posts: 738
Location: Belgium
So, did anyone try this one out ? If there are no issues I can post this to the repo team.

Umbraco tips and tricks: http://www.nibble.be - umbraco mvp 08/09 - certified level 1 & 2 professional
sthurein
Posted: Tuesday, December 04, 2007 1:21:12 AM
Rank: Newbie

Joined: 7/12/2007
Posts: 7
Hi Tim,

I've installed it on my test server and there hasn't been any issues in the last two weeks. If nothing goes wrong in the next week or so, I'll look at putting it on my production box.

Cheers
S
jesper
Posted: Tuesday, December 04, 2007 8:48:31 AM

Rank: Administration

Joined: 7/25/2006
Posts: 415
Location: vipperoed, denmark
Great one Tim,

How about throwing the config file in the config folder and change the extension to .config. V3 style :)

Kindly,

Jesper

webbureau jesper.com doing webdesign / development / umbraco implementations / 2007&2008 MVP
tim
Posted: Tuesday, December 04, 2007 1:33:06 PM

Rank: Addict

Joined: 2/19/2007
Posts: 738
Location: Belgium
Sure, that would be possible,

So what would be best,

/config/pingxmlrpc.config

or

/config/plugins/pingxmlrpc.config

or

/config/plugins/tg/pingxmlrpc.config

Would be nice to have some kind of guidlines for future packages ...

Package team, what do you think ?



Umbraco tips and tricks: http://www.nibble.be - umbraco mvp 08/09 - certified level 1 & 2 professional
tim
Posted: Tuesday, December 04, 2007 1:36:54 PM

Rank: Addict

Joined: 2/19/2007
Posts: 738
Location: Belgium
Or Use packages instead of plugins to avoid any misunderstanding


/config/packages/tg/pingxmlrpc.config

Umbraco tips and tricks: http://www.nibble.be - umbraco mvp 08/09 - certified level 1 & 2 professional
jesper
Posted: Tuesday, December 04, 2007 2:06:23 PM

Rank: Administration

Joined: 7/25/2006
Posts: 415
Location: vipperoed, denmark
I'm not package team but I would go for either:

/config/pingxmlrpc.config

or

/config/pingxmlrpc/someconfigname.config


This way ensuring that when it comes to configuring Umbraco stuff you always know where .. kind of control panel ( or Apple System Preferences ).

Kindly,

Jesper

webbureau jesper.com doing webdesign / development / umbraco implementations / 2007&2008 MVP
warren
Posted: Tuesday, May 20, 2008 6:43:16 PM

Rank: Addict

Joined: 7/19/2006
Posts: 777
Location: Leigh-on-Sea, Essex, UK
Tim,
In regards to this PING package its great however why does it PING the parent URL and not the actual node in question?

//Warren

Warren Buckley an Umbraco MVP 08-09 & level 1 certified developer
tim
Posted: Wednesday, May 21, 2008 9:06:57 AM

Rank: Addict

Joined: 2/19/2007
Posts: 738
Location: Belgium
Hi Warren, I'll have to check this one, but I think this is standard behaviour.

Umbraco tips and tricks: http://www.nibble.be - umbraco mvp 08/09 - certified level 1 & 2 professional
SoerenS
Posted: Wednesday, May 21, 2008 5:36:05 PM

Rank: Fanatic

Joined: 7/25/2006
Posts: 424
Location: Silkeborg, Denmark
VERY nice package! I've actually been thinking about doing one myself, now I don't have to do all that work :-)

I agree, PINGing with the parent URL is standard behaviour, for some weird reason. Not sure why the standard doesn't include the URL to the actual latest post also.

One question: Why use ParentDocumentTypeAlias, and not just ParentDocument?

/SoerenS

Brug for råd til hvordan du driver en god webshop? / Need advice on how to run an effective webshop?
warren
Posted: Friday, May 23, 2008 1:48:31 PM

Rank: Addict

Joined: 7/19/2006
Posts: 777
Location: Leigh-on-Sea, Essex, UK
Tim, Soren can you supply me with a spec that details about pinging the parent URL as opposed to the actual new content page?

Secondly Tim is it possible to modify the package to get it to work to ping sitemaps to google?
http://www.google.com/support/webmasters/bin/answer.py?hl=en&answer=34609

Warren Buckley an Umbraco MVP 08-09 & level 1 certified developer
SoerenS
Posted: Friday, August 08, 2008 2:40:49 PM

Rank: Fanatic

Joined: 7/25/2006
Posts: 424
Location: Silkeborg, Denmark
warren wrote:
Tim, Soren can you supply me with a spec that details about pinging the parent URL as opposed to the actual new content page?

Well, I was thinking that it should just listen for all new posts under a specific node. Instead of certain aliases under a parent alias.

Not sure why exactly I was thinking that, since it seems like the current functionality easily can be used for the structure on my own blog.

/SoerenS

Brug for råd til hvordan du driver en god webshop? / Need advice on how to run an effective webshop?
Users browsing this topic
Guest


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.