Blendy - Blog Entry Distributor
I would categorize a BLOG content into mainly two groups. One for Broadcasting my opinion, which can be one about a social, political, technical, or entertainmental stuffs, to the world. I want as many people as possible to listen my voice. And the other is wholly for LOGging my personal affairs. I don't care who would see it or not.
Then, what means do I have in order to broadcate my post? How can I provide more opportunity for the world to take something from my posts? It can be possible by using meta blog sites, various syndication feeds, trackback pings or so. Are you satisfied?
At first, I developed this plugin for the purpose of reposting (full entry content) or publicizing ( just entry body text plus a link to my original MT entry) my some entries, the characteristic of which is for broadcasting my thoughts, knowledges, and tips or so, to the other big blog commnunities in which they generally provide their own recent updated/random blog/today top hits entry and so on. In Korea, nearly all portal sites provide free(really free? they have so many ad banners) blog service. They have comparatively firm commnunity. So I couldn't ignore those commnunities' opinion power. It's my first momentum to make me develope Blendy.
Afterwards I found in Pronet this plugin could do more works I didn't expect. For example, let's imagine the situation that one blog is written in English, and some translators have their own blogs in local or remote system, and their contents are same with English one but only different in their expressed language. In this situation, a English writer posts an entry to his blog, and then she distritutes her English entry into other blogs for translation. Then each translators only have to translate that entry on their blog into other language. In this workflow, Blendy can be helpful.
Any other useful usages are also possible, however, it wholly depends on your imagination.
Requirement
Blendy plugin itself doesn't need any other Perl module.
Some example BlendyCGIs require HTML::HeadParser or Net::MovableType Perl module.
Installation
Download this plugins and untar it under mt home folder, then files wil be located as below.
- (mt home)/plugins/alogblog/Blendy.pl
- (mt home)/plugins/alogblog/tmpl/blendy.tmpl
- (mt home)/plugins/alogblog/images/blendy.gif
- (mt home)/plugins/alogblog/BlendyCGI/movabletype-XMLRPC.cgi
- (mt home)/plugins/alogblog/BlendyCGI/movabletype-HTTP.cgi
- (mt home)/plugins/alogblog/BlendyCGI/livejournal.cgi
- (mt home)/plugins/alogblog/BlendyCGI/blogspot.cgi
Configuration
In each blog's plugin list, you can configure three options.
- CGI extensions : All files having these extensions under BlendyCGI folder will be treated as CGI for Blendy. Default is 'cgi pl php asp'.
- CGI Base URL : If you move default BlendyCGI folder, its URL also will be change. In here, you set its base URL
- CGI Base Path : Absolute BlendyCGI folder path
If you installed it in default path, you don't need to change these.
Work-flow
Fig. 1: Overall work-flow

Fig. 2 : First, you select entries to send to BlendyCGI (it acts like a proxy) in Entry Listing page. You can also do this in Entry Edit page.

Fig. 3: In this menu page, you enter your password. Of course, this password is of some blogs you want to post. Normally it assumes you use the same password in all blogs.(If you don't, see notes below.) And then select which blogs you want to post.

Fig. 4: Blendy action plugin sends nearly all entry data to each BlendyCGIs. Then BlendyCGIs re-send (ie. post) data to targeted local or remote blogs.

BlendyCGI
Blendy CGI scripts are not part of Blendy plugin. Plugin just look into BlendyCGI/ folder and if it find files having some extention, it deals them as BlendyCGI. This plugin's role is only to send selected entries data to those BlendyCGIs. It send data by HTTP POST method to CGI. After then, its role is over. Next step is up to CGI.
BlendyCGI( a CGI working with Blendy plugin) gets nearly all entry data(title, body, extended body, excerpt if any, keywords, all categories info, time stamp, comment and ping status, what is more, publish encoding, time zone, permalink, filtered body, filtered extended boy, etc.), because plugin doen't know what data of entry will CGI need.
After getting data of entry, you can do anything in CGI with that data. You can program CGI that posts to TypePad, OR that exports serveral entries, not all of a blog, to a file, OR that converts an entry into PDF file if you can, OR publishes static HTML page applied by special purpose templates(don't ask me why, it's only example.) OR post to other MT for translation OR, OR. It depends on your needs.
I provided 2 GGIs, movabletype-HTTP.cgi and movabletype-XMLRPC.cgi for Movable Type. movabletype-XMLRPC.cgi uses Net::MovableType Perl module which uses XMLRPC. So if you have Net::MovableType installed, you can satisfiedly post an entry to MT. I added also the same functiong CGI, movabletype-HTTP.cgi, which use only HTTP protocol. There is some reason I added it too. If your category name is of not Latin but Korean, Japanese or so, then MT's XMLRPCServer didn't recognize it well, as a result, an entry having no category was created. But by using normal HTTP POST method, there was no such problem.
If you create BlendyCGI for your own need, you must keep just one rule. That is, if your purposed work is well done, just print out "success" message as like,
print "Content-type: text/html\n\nsuccess";
Then, Blendy plugin records that success into MT's database so as not to re-post the same entry inadvertently in future.
If you want to use example CGI, open it then some comments will tell you how to configure your environments.
Notes
1.
I have some portal blogs I want to post my MT entries, but each has diffrent passwords. How can I solve it with Blendy's only one password input field?
In that case, use Blendy's password input value as like a Master Key. For example, you set M.K to 123456, then in each CGI, check validity of MA as below.
if($q->param('pswd') eq '123456') { $pswd = 'real password'; } else { die; }
License
Released under the Creative Commons License.
Version History
- 3.2.01: for MT 3.2
- 1.0: for MT 3.17, in the name of SyncBlog
Post a comment