addthis Menu API in flash

Posted: Wednesday, June 2, 2010 by Venkat Pola in Labels:


For flash, we have to use share end point API. But unfortunately we have so many limitations in this API. Actually Menu API provides so many features like ( Email tempaltes, service exclude and all... etc) but we can use this API in only in javascript.

I have a strong requirement to use Menu API in flash, so to achieve this i have written one wrapper page, please find the above url for this page. Where type is either "more" or "email".

Solution:- Copy the source code of this page and host it in your webserver and invoke this page from flash as

var addthis_config:String ="{" +
"username: '"+getAddThisParam("username")+"'," +
"ui_use_addressbook: "+getAddThisParam("ui_use_addressbook")+"," +
"ui_cobrand: '"+getAddThisParam("ui_cobrand")+"'" +

var addthis_share:String="{" +
"title:'"+getAddThisParam("title")+"', " +
"url:'"+getAddThisParam("url")+"', " +
"swfurl:'"+getAddThisParam("swfurl")+"', " +
"height:'"+getAddThisParam("height")+"', " +
"width: '"+getAddThisParam("width")+"', " +
"screenshot:'"+getAddThisParam("screenshot")+"', "+
"email_template:'"+getAddThisParam("email_template")+"', " +
"email_vars: {"+emailVars_key_value+"}, "+
"templates:{twitter:'"+getAddThisParam("twitter")+"'}" +

var type="email" or var type="more"

var request:URLRequest = new URLRequest(configPath+"static/openMenu.html?addthis_config="+addthis_config+"&addthis_share="+addthis_share+"&type="+type);


I hope,all of you get it how to make use of Menu API in flash.

Good luck!!

Enhanced by Zemanta