Sunday, May 6, 2012

开发工具

 
 

Batch

2012年2月24日

20:01

 
 

拷贝文件批处理

 
 

源文档 <http://wenwen.soso.com/z/q158925681.htm>

 
 

 
 

js格式化工具

2012年2月23日

20:48

 
 

http://tool.chinaz.com/Tools/JsFormat.aspx 能够将段落很差的处理成可视化

 
 

Dom inspector

2012年2月22日

20:36

 
 

输入: chrome://browser/content/browser.xul

 
 

 
 

工具研究过程

2012年2月22日

20:47

 
 

放在D:\rubbish\download

 
 

Facebook

2012年2月22日

21:26

 
 

打开设置窗口

2012年2月22日

21:26

 
 

chrome://facebook/content/settings.xul

 
 

仿插件

2012年2月22日

21:25

 
 

弹出窗口

2012年2月25日

17:46

 
 

class="notification_popup"

 
 

Fttoolbar.xul

2012年2月23日

20:39

 
 

FC_Toolbarafe43e800abc4df281a03fe44b74abe8 是我们要模仿功能的toolbar.id

更名为MMOSITE_TOOLBAR_STEP1

 
 

Friends

2012年2月22日

20:55

 
 

url="http://gamersunite.coolchaser.com/toolbar/one_click_friends"

 
 

 
 

 
 

1-click gifts

2012年2月22日

20:47

 
 

查询:http://gamersunite.coolchaser.com/toolbar/include?gu=true

返回:

<toolbar xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul" > <toolbaritem component="banner" cid="2807318" preview_text="Snagger"> <fctb_banner url="http://gamersunite.coolchaser.com/toolbar/banner?c=1329914720" expire="720" sync="" width="200" height="20" visibility="1"/> </toolbaritem> <toolbaritem cid="2807596" component="link" preview_text="Home"> <toolbarbutton cmd="redirect" label="Home" image="http://cdn.nextsmallthings.com/tbar/toolbarlogo2.png" url="http://gamersunite.coolchaser.com"/> </toolbaritem> <toolbaritem cid="buttonbubble" preview_text="buttonbubble"> <toolbarbutton cmd="show-popup" url="http://gamersunite.coolchaser.com/toolbar/one_click_friends" position="top-right" w="300" h="550" timeout="86400" image="http://assets.gamersunite.com/images/group.png" label="Friends (NEW!)" /> </toolbaritem> <toolbaritem cid="2807598" component="link" preview_text="1-Click Gifts"> <toolbarbutton cmd="redirect" label="1-Click Gifts" image="http://cdn.nextsmallthings.com/tbar/mouse.png" url="http://gamersunite.coolchaser.com/toolbar/fb_request_page"/> </toolbaritem> <toolbaritem component="dropdown" collapsed="false" cid="2809733" preview_text="Feeds"> <toolbarbutton type="menu" label="Feeds" image="http://img.freecause.com/62565/dropdownitem_2809733_3.png?r=17"> <menupopup> <menuitem label="Adventure World" image="http://cdn.nextsmallthings.com/tbar/icon_aw.png" cmd="redirect" url="http://gamersunite.coolchaser.com/games/adventure-world/myfeed" class="menuitem-iconic" /> <menuitem label="CastleVille" image="http://cdn.nextsmallthings.com/tbar/crown.png" cmd="redirect" url="http://gamersunite.coolchaser.com/games/castleville/myfeed" class="menuitem-iconic" /> <menuitem label="Café World Feed" image="http://cdn.nextsmallthings.com/tbar/icon_cafeworld.png" cmd="redirect" url="http://gamersunite.coolchaser.com/games/caf-eacute-world/myfeed" class="menuitem-iconic" /> <menuitem label="Cityville Feed" image="http://cdn.nextsmallthings.com/tbar/icon_cityville.png" cmd="redirect" url="http://gamersunite.coolchaser.com/games/cityville/myfeed" class="menuitem-iconic" /> <menuitem label="Empires &amp; Allies Feed" image="http://cdn.nextsmallthings.com/tbar/icon_eaa.png" cmd="redirect" url="http://gamersunite.coolchaser.com/games/empires-allies/myfeed" class="menuitem-iconic" /> <menuitem label="FarmVille Feed" image="http://cdn.nextsmallthings.com/tbar/icon_farmville.png" cmd="redirect" url="http://gamersunite.coolchaser.com/games/farmville/myfeed" class="menuitem-iconic" /> <menuitem label="Hidden Chronicle" image="http://cdn.nextsmallthings.com/tbar/hourglass.png" cmd="redirect" url="http://gamersunite.coolchaser.com/games/hidden-chronicles/myfeed" class="menuitem-iconic" /> <menuitem label="Pioneer Trail Feed" image="http://cdn.nextsmallthings.com/tbar/icon_frontierville.png" cmd="redirect" url="http://gamersunite.coolchaser.com/games/pioneer-trail/myfeed" class="menuitem-iconic" /> <menuitem label="The Sims Social Feed" image="http://cdn.nextsmallthings.com/tbar/icon_ss.png" cmd="redirect" url="http://gamersunite.coolchaser.com/games/the-sims-social/myfeed" class="menuitem-iconic" /> <menuseparator id="separator"/> <menuitem label="My Games Feed" image="http://img.freecause.com/62565/dropdownitem_2809733_2.png?r=17" cmd="redirect" url="http://gamersunite.coolchaser.com/mygames" class="menuitem-iconic" /> </menupopup> </toolbarbutton> </toolbaritem> <toolbaritem component="dropdown" collapsed="false" cid="2809734" preview_text="Play"> <toolbarbutton type="menu" label="Play"

image="http://s3wizard.freecause.com/iconsets_entertainment_63%20controller.png">

<menupopup>

<menuitem
label="Adventure World"
image="http://cdn.nextsmallthings.com/tbar/icon_aw.png"

cmd="redirect"
url="http://apps.facebook.com/playadventureworld/"
class="menuitem-iconic"
/>

<menuitem
label="Empires &amp; Allies"
image="http://cdn.nextsmallthings.com/tbar/icon_eaa.png"

cmd="redirect"
url="http://apps.facebook.com/empiresandallies"
class="menuitem-iconic"
/>

<menuitem
label="Café World"
image="http://cdn.nextsmallthings.com/tbar/icon_cafeworld.png"

cmd="redirect"
url="http://apps.facebook.com/cafeworld/"
class="menuitem-iconic"
/>

<menuitem
label="Castleville"
image="http://cdn.nextsmallthings.com/tbar/crown.png"

cmd="redirect"
url="http://apps.facebook.com/playcastleville/"
class="menuitem-iconic"
/>

<menuitem
label="Cityville"
image="http://cdn.nextsmallthings.com/tbar/icon_cityville.png"

cmd="redirect"
url="http://apps.facebook.com/cityville/"
class="menuitem-iconic"
/>

<menuitem
label="Farmville"
image="http://cdn.nextsmallthings.com/tbar/icon_farmville.png"

cmd="redirect"
url="http://www.farmville.com"
class="menuitem-iconic"
/>

<menuitem
label="Hidden Chronicles"
image="http://cdn.nextsmallthings.com/tbar/hourglass.png"

cmd="redirect"
url="http://apps.facebook.com/hidden-chronicles/"
class="menuitem-iconic"
/>

<menuitem
label="Pioneer Trail"
image="http://cdn.nextsmallthings.com/tbar/icon_frontierville.png"

cmd="redirect"
url="http://apps.facebook.com/pioneertrail/"
class="menuitem-iconic"
/>

<menuitem
label="The Sims Social"
image="http://cdn.nextsmallthings.com/tbar/icon_ss.png"

cmd="redirect"
url="http://apps.facebook.com/thesimssocial"
class="menuitem-iconic"
/>

</menupopup>

</toolbarbutton>

</toolbaritem>

<toolbaritem
cid="2807592"
component="link"
preview_text="Reload Toolbar">

<toolbarbutton
cmd="redirect"
label="Reload Toolbar"

image="http://cdn.nextsmallthings.com/tbar/arrow_circle_double_135.png"

url="http://gamersunite.coolchaser.com/toolbar/reload"/>

</toolbaritem>

<toolbaritem
cid="2807591"
component="link"
preview_text="Facebook">

<toolbarbutton
cmd="redirect"
label="Facebook"

image="http://img.freecause.com/62387/dropdownitem_2807591_0.png?r=13"

url="http://www.facebook.com"/>

</toolbaritem>

<toolbaritem
component="include_js"
cid="ssl_one_click"
preview_text="Include_js">

<fctb_include_js
random_function="0"
init="1">

<target><![CDATA[^https:\/\/www\.facebook\.com]]></target>

<target><![CDATA[^https:\/\/.*facebook\.com\/.*\/serverfbml\.php$]]></target>

<![CDATA[<script
type=text/javascript
src="https://gamersunite.coolchaser.com/sprockets/autoaccept?cachebust=1329914720">]]>

</fctb_include_js>

</toolbaritem>

</toolbar>

 
 

查询:

http://assets.gamersunite.com/sprockets/autoaccept.js?0.90

 
 

返回:

Date.prototype.toRelativeTime = function(now_threshold) {
var delta = new Date() - this;
now_threshold = now_threshold || 60000;
now_threshold = parseInt(now_threshold, 10);

if (isNaN(now_threshold)) {
now_threshold = 0;
}

if (delta <= now_threshold) {
return 'mere moments ago';
}

var units = null;
var conversions = {
millisecond: 1, // ms -> ms
second: 1000, // ms -> sec
minute: 60, // sec -> min
hour: 60, // min -> hour
day: 24, // hour -> day
month: 30, // day -> month (roughly)
year: 12 // month -> year
};

for (var key in conversions) {
if (delta < conversions[key]) {
break;
} else {
units = key; // keeps track of the selected key over the iteration
delta = delta / conversions[key];
}
}

delta = Math.floor(delta);
if (delta !== 1) { units += "s"; }
return [delta, units, "ago"].join(" ");
};
if (!Date.now) {Date.now = function() {return new Date().getTime();};}
var _Toolbar = {
        TotalKey: 'fv_total',
        SessionCount: 'session',
        AppsCountKey: 'apps_count',
UnItemsKey: 'unitems',
UngrpsObjsKey: 'ungrpsobjs',
GrpsObjsKey: 'grpsobjs',
        AlertKey: 'fbg_message',
        LoginMsg: 'needs_login',
AutoLikeKey: 'auto_like1',
AutoLikeKey3: 'auto_like3',
AutoCommentKey: 'auto_comment',
NeighborlyKey: 'neighborly',
Log: 'log',
LastSuccess: 'success_stamp',
LastSnagUpdate: 'snag_stamp',
PostsKey: 'posts',
VersionKey: 'version',
BannerCID: 2807318,
Active: 'active',
DontNotifyKey: 'dont_notify',
UnAutoAcceptKey: 'unauto_accept',
TestAutoAccept: 'test_accept',
UnAppIdsKey: 'appids',
AppIdsKey: 'appids2',
StreamGetKey: 'dostreamget',
SnagLimitsPref: 'snag_limits',
ActiveFriendsNum: 'active_friends_num',
ActiveFriendsPref:'active_friends',
LastPopupKey: 'last_popup',
Unchecked1CF: 'unchecked_active_friends',
GamesInfo: 'games_info',
Inited: 'inited',
init: function(tool) {
this.toolbar = tool;
this.ridHash = {};
},
inited: function() {
return !!this.toolbar;
},
isGUBar: function(tool) {
var toolbar = tool || this.toolbar;
var guBars = ['60531', '60639', '62565', '62703', '62781', '62841'];
for (var i=0;i<guBars.length;++i) {
if (toolbar.toolid == guBars[i]) {return true;}
}
return false;
},
login: function(userid) {
if (this.toolbar && this.toolbar.sessionUser != userid) {
this.toolbar.Options.Authenticated(userid,'pw', '1', true);
}
},
reload :function() {
this.toolbar.ReloadByCid(_Toolbar.BannerCID);
this.toolbar.Reload();
},
restoreDefaults: function() {
if (this.toolbar.CallCmd) {toolbar.CallCmd('reset_layout');}
else {this.toolbar.callcmd('display_layout');}
},
put: function(key, val) {
if (!this.toolbar) {
if (window.localStorage) {localStorage.setItem(key, val);}
return;
}
if (val) {
var json_val = Object.toJSON && Object.toJSON(val) || JSON && JSON.stringify(val);
this.toolbar.SetVariable(key, json_val);
}
else {this.toolbar.SetVariable(key,'');}
},
get: function(key, dflt) {
if (!this.toolbar && window.localStorage) {
return localStorage.getItem(key) || dflt;
}
try {
var val = this.toolbar.GetVariable(key);
if (val) {return val.evalJSON && val.evalJSON(true) || JSON && JSON.parse(val);}
return dflt || null;
}
catch(e) {
return dflt || null;
}
},
log: function(str, key) {
key = key || this.Log;
var newEntry = str + ' - ' + new Date().toString() + "\n";
var log = newEntry + (this.getLog(key) || '');
log = log.slice(0,30000);
this.put(key, log);
if (window.console) {console.log(newEntry);}
},
logException: function(label, exception) {
var exceptionStr = Object.toJSON && Object.toJSON(exception) || JSON && JSON.stringify(exception);
_Toolbar.log(label + exceptionStr);
},
notifyEvent: function(evt, param) {
this.toolbar.notifyAllInstances(this.BannerCID, evt, param);
},
clearLog: function(key) {
key = key || this.Log;
this.put(key, '');
},
getLog: function (key) {
key = key || this.Log;
try {
return this.get(key);
}
catch(e) {
this.clearLog();
this.log('error in log ' + e);
return '';
}
},
getId: function() {
return this.toolbar && this.toolbar.toolid;
},
gotoUrl: function(url, newTab) {
var anchorText = newTab ? "#newwindow" : "#mainwindow";
this.toolbar.toolbarInvoke('browserNavigate', url + anchorText);
},
showPopup: function(url, delay) {
this.toolbar.ShowPopup(url, 300, 110, "bottom-left", "", delay, 10,'');
},
makeAsyncRequest: function(url, nextState, remember, callback, postParams, httpHeaders) {
httpHeaders = httpHeaders || '';
postParams = postParams || '';
var rid = this.toolbar.RequestURLAsync2(url, httpHeaders, "", postParams);
if (!this.ridHash) {this.ridHash = {};}
this.ridHash[rid] = {url:url, next:nextState, ref:remember, cb:callback};
},
asyncRequestDone: function(rid, success, content) {
if (success && content) {
var ridState = this.ridHash[rid];
if (!ridState) {return;}
try {
delete this.ridHash[rid];
ridState.cb(content, ridState.next, ridState.ref);
} catch(e) {
_Toolbar.logException('rid url ' + ridState.url, e);
_Toolbar.log(e.stack);
}
}
else {
_Toolbar.log('@@@ async request failed: ' + rid + ' content:' + content);
}
},
isShopping: function() {
return !this.toolbar.getSettingByType('option', 'DisableShoppingComponent');
},
setShopping: function(state) {
this.toolbar.setSettingByType('option', 'DisableShoppingComponent', (state ? 0 : 1));
},
checkOldSnags: function(lastSnag) {
if (_Toolbar.get(_Toolbar.LastSnagUpdate) < lastSnag) {
_Toolbar.put(_Toolbar.LastSnagUpdate, lastSnag);
_Toolbar.notifyEvent('refresh_snags');
return true;
}
return false;
},
getAppIds: function() {
var appIds = _Toolbar.get(_Toolbar.AppIdsKey);
if (!appIds) {
var unappIds = _Toolbar.get(_Toolbar.UnAppIdsKey) || [201278444497,291549705119,101539264719];
appIds = [].without.apply([102452128776,201278444497,291549705119,101539264719], unappIds);
_Toolbar.put(_Toolbar.UnAppIdsKey,null);
_Toolbar.setAppIds(appIds);
}
if (appIds instanceof Array && appIds.include(201278444497)) {
appIds = appIds.without(201278444497);
_Toolbar.setAppIds(appIds);
}
return appIds;
},
setAppIds: function(appIds) {
_Toolbar.put(_Toolbar.AppIdsKey, appIds);
},
getMainUrl: function() {
return unescape(this.toolbar.parseUrlVars('%url'));
}
};
function ActiveFriends(fbuid, gameId) {
this.appId = gameId;
this.fbuid = fbuid;
}

ActiveFriends.prototype = {
getKey: function() {
return 'ap_' + this.appId + '_' + this.fbuid;
},
getHash: function(sync) {
if (sync || !this.hash) {
this.hash = _Toolbar.get(this.getKey(), {});
}
return this.hash;
},
addFriend: function(friendInfo) {
friendInfo.createdAt = friendInfo.createdAt || Date.now();
var hash = this.getHash();
var oldTime = (hash[friendInfo.fbuid] && hash[friendInfo.fbuid].createdAt) || 0;
if (friendInfo.createdAt > oldTime) {
hash[friendInfo.fbuid] = friendInfo;
}
},
storeHash: function() {
if (this.hash) {
_Toolbar.put(this.getKey(), this.hash);
}
},
addFriendsSync: function() {
this.getHash(true);
for(var i=0;i<arguments.length;++i) {
if (arguments[i]) {this.addFriend(arguments[i]);}
}
this.storeHash();
},
mostActive: function() {
var keys = [];
var hash = this.getHash();
for (var key in hash) {keys.push(key);}
keys.sort(function(arg1, arg2) {return hash[arg2].createdAt - hash[arg1].createdAt;});
if (keys.length > 150) {
keys = keys.slice(0,150);
for (var key in hash) {if (keys.indexOf(key) == -1) {delete hash[key];}}
this.storeHash();
}
return keys;
},
mostActiveInfo: function() {
var keys = this.mostActive();
var hash = this.getHash();
return keys.map(function(key) {return hash[key];});
}
};

ActiveFriends.addMultiGames = function(fbuid, gamesHash) {
for(var appId in gamesHash) {
var ap = new ActiveFriends(fbuid, appId);
var friends = gamesHash[appId];
ap.addFriendsSync.apply(ap, friends);
}
};

function ActiveFriendInfo(fbuid, label, timestamp) {
this.fbuid = fbuid;
this.label = label;
this.timestamp = timestsamp || Date.now();
}

ActiveFriendInfo.sort = function(a,b) {
return a.timestamp < b.timestamp;
};
var _ActiveFriendsSelector = {
InjectHTML:'<div class="gu_logo"><img src="@urlprefix@/images/toolbarlogo2.png" class=gu_s_icon></div><div class="gu_select"><select class="gu_num_friends"><option value=10>Add 10 Active Friends<option value=20>Add 20 Active Friends<option value=30>Add 30 Active Friends<option value=40>Add 40 Active Friends</select> <a id="gu_select" href="#" class=gu_button>GO!</a> <div class="gu_support"><a class="gu_refresh" href="http://gamersunite.coolchaser.com/toolbar/one_click_tools?app_id=@appid@" target=_blank>refresh<div class="gu_tips">Refresh active friends list</div></a><a class="gu_help" href="http://gamersunite.coolchaser.com/toolbar/one_click_tools?app_id=@appid@" target=_blank>help<div class="gu_tips">Learn more about 1-Click Friends</div></a></div></div>',
NoFriendsHTML: '<div class="gu_logo"><img src="@urlprefix@/images/toolbarlogo2.png" class=gu_s_icon></div><div class="gu_select">No active friends found :( Make sure you visit the <a href=" http://www.facebook.com/games" target=_blank>Game Requests</a> & <a href="http://gamersunite.coolchaser.com/toolbar/one_click_tools?myfeed=1&app_id=@appid@" target=_blank>My Feed </a> pages. <a href="http://gamersunite.coolchaser.com/toolbar/one_click_tools?app_id=@appid@" target=_blank>Learn more &raquo;</a></div>',
isFriendsSelector: function() {
var isFbml = document.URL.indexOf('serverfbml.php') > 0;
return isFbml && !!this.findAppId();
},
findAppId: function() {
if (this.appid) {return this.appid;}
var children = document.body.children;
for (var i=0; i<children.length; ++i) {
var child = children[i];
if (child.id && child.id.startsWith("app_content_")) {
var idElts = child.id.split('_');
this.appid = idElts[idElts.length-1];
return this.appid;
}
}
return null;
},
getFbuid: function() {
return Env.user;
},
replaceAppIdInHtml: function(html) {
return html.replace(/@appid@/g, this.findAppId());
},
getInjectionHTML: function() {
var html='';
if (!_Toolbar.get(_Toolbar.Unchecked1CF)) {
var ap = new ActiveFriends(this.getFbuid(), this.findAppId());
html = (ap.mostActive().length == 0) ? this.NoFriendsHTML : this.InjectHTML;
}
html = _InsideFB.replaceUrlPrefix(html);
return this.replaceAppIdInHtml(html);
},
inject: function() {
_InsideFB.insertStylesheet("@urlprefix@/stylesheets/top_friends.css?1");
this.injectHTML();
this.setDefaultNumFriends();
},
showStatus: function(containingDiv, str) {
var mombar = DOM.find(containingDiv, '.gu_mombar');
if (mombar) {
var statusDiv = $N('div', {className:'gu_selected'});
CSS.setStyle(statusDiv, 'opacity', 0);
mombar.appendChild(statusDiv);
statusDiv.innerHTML = str;
animation(statusDiv).from('opacity',0).to('opacity',1).duration(400).go();
window.setTimeout(function() {
animation(statusDiv).from('opacity',1).to('opacity',0).duration(400).
ondone(function() {mombar.removeChild(statusDiv);}).go();
}, 3000);
}
},
injectHTML: function() {
var html = this.getInjectionHTML();
if (html) {
var wrapperDivs = DOM.scry(document, '.fb_protected_wrapper');
var selectedDivs = [];
var self = this;
wrapperDivs.forEach(function(div) {
if (self.candidateWrapper(div) && !self.childOfDivs(div, selectedDivs)) {
selectedDivs.push(div);
}
});
selectedDivs.forEach(function(div) {self.injectIntoWrapper(div, html);});
}
},
candidateWrapper: function(candidate) {
return !!DOM.find(candidate, '.unselected_list input.inputcheckbox');
},
childOfDivs: function(child, divs) {
return divs.filter(function(parentDiv) {return DOM.contains(parentDiv, child);}).length > 0;
},
injectIntoWrapper: function(fbDiv, html) {
var mombarDiv = $N('div', {className:'gu_mombar'});
mombarDiv.innerHTML = html;
DOM.prependContent(fbDiv, mombarDiv);
var guBtn = DOM.find(fbDiv, '.gu_button');
if (guBtn) {guBtn.onclick = this.selectFriends.bind(this, fbDiv);}
},
selectFriends: function(friendsListDiv) {
function findInputWithValue(inputs, fbuid) {
for(var i=0;i<inputs.length;++i) {
var input = inputs[i];
if (input.value == fbuid && input.parentNode.style.display != 'none') {
return input;
}
}
return null;
}

var inputs = DOM.scry(friendsListDiv, '.unselected_list input.inputcheckbox');
if (inputs.length > 0) {
var ap = new ActiveFriends(this.getFbuid(), this.findAppId());
var mostActive = ap.mostActive();
var mostActiveInList = mostActive.filter(function(fbuid) {return findInputWithValue(inputs, fbuid);});
var mostActiveToSelect = mostActiveInList.slice(0,_Toolbar.get(_Toolbar.ActiveFriendsNum,20));
for(var i=0;i<mostActiveToSelect.length;++i) {
var input = findInputWithValue(inputs, mostActiveToSelect[i]);
if (input) {input.click();}
}
var statusStr = mostActiveToSelect.length > 0 ? (mostActiveToSelect.length + ' added!') :
'No (more) active friends found on this list (try the "All Friends" tab, if present)';
this.showStatus(friendsListDiv, statusStr);
}
},
setDefaultNumFriends: function() {
var selectInputs = DOM.scry(document, "select.gu_num_friends");
var defaultVal = _Toolbar.get(_Toolbar.ActiveFriendsNum, 20);
selectInputs.each(function(select) {
select.value = defaultVal;
select.onchange = function() {_Toolbar.put(_Toolbar.ActiveFriendsNum, select.value);};
});
}
};

var _ActiveFriendsZ = {
InjectHTML:'<div class="gu_logo"><img src="@urlprefix@/images/toolbarlogo2.png" class=gu_s_icon></div><div class="gu_select"><select class="gu_num_friends"><option value=10>Add 10 Active Friends<option value=20>Add 20 Active Friends<option value=30>Add 30 Active Friends<option value=40>Add 40 Active Friends</select> <a id="gu_select" href="#" class=gu_button>GO!</a> <div class="gu_support"><a class="gu_refresh" href="http://gamersunite.coolchaser.com/toolbar/one_click_tools?app_id=@appid@" target=_blank>refresh<div class="gu_tips">Refresh active friends list</div></a><a class="gu_help" href="http://gamersunite.coolchaser.com/toolbar/one_click_tools?app_id=@appid@" target=_blank>help<div class="gu_tips">Learn more about 1-Click Friends</div></a></div></div>',
NoFriendsHTML: '<div class="gu_logo"><img src="@urlprefix@/images/toolbarlogo2.png" class=gu_s_icon></div><div class="gu_select">No active friends found :( Make sure you visit the <a href=" http://www.facebook.com/games" target=_blank>Game Requests</a> & <a href="http://gamersunite.coolchaser.com/toolbar/one_click_tools?myfeed=1&app_id=@appid@" target=_blank>My Feed </a> pages. <a href="http://gamersunite.coolchaser.com/toolbar/one_click_tools?app_id=@appid@" target=_blank>Learn more &raquo;</a></div>',
FBIdSet: ['101539264719', '266989143414', '10979261223', '234860566661', '151044809337', '25287267406'],
isFriendsSelector: function() {
if (!window.jQuery) {return false;}
var isZSelector = jQuery('.zui_listselector_dual_unselected_item').length > 5;
return isZSelector && (jQuery.inArray(this.findAppId(),this.FBIdSet) != -1);
},
findAppId: function() {
if (this.appid) {return this.appid;}
this.appid = FB._apiKey + '';
return this.appid;
},
getFbuid: function() {
return FB.getUserID();
},
replaceAppIdInHtml: function(html) {
return html.replace(/@appid@/g, this.findAppId());
},
getInjectionHTML: function() {
var html='';
if (!_Toolbar.get(_Toolbar.Unchecked1CF)) {
var ap = new ActiveFriends(this.getFbuid(), this.findAppId());
html = (ap.mostActive().length == 0) ? this.NoFriendsHTML : this.InjectHTML;
}
html = _InsideFB.replaceUrlPrefix(html);
return this.replaceAppIdInHtml(html);
},
inject: function() {
_InsideFB.insertStylesheet("@urlprefix@/stylesheets/top_friends.css?1");
this.injectHTML();
this.setDefaultNumFriends();
},
showStatus: function(containingDiv, str) {
var mombar = $(containingDiv).find('.gu_mombar');
if (mombar) {
var statusDiv = $('<div class="gu_selected" style="display:none"></div>');
statusDiv.text(str);
mombar.append(statusDiv);
statusDiv.fadeIn(400, function() {
window.setTimeout(function() {
statusDiv.fadeOut(400,function() {statusDiv.remove();});
}, 3000);
});
}
},
injectHTML: function() {
var html = this.getInjectionHTML();
if (html) {
this.injectIntoWrapper($('div.zui_mfs_selector'), html);
}
},
injectIntoWrapper: function(fbDiv, html) {
var mombarDiv = $('<div class="gu_mombar"></div>');
mombarDiv.html(html);
$(fbDiv).prepend(mombarDiv);
var guBtn = $(fbDiv).find('.gu_button');
guBtn.click($.proxy(this.selectFriends, this));
},
selectFriends: function() {
var inputs = $('.zui_listselector_dual_unselected_item input').
not('.zui_listselector_dual_unselected_item_hidden input');
if (window.DAPI) {
var ids = inputs.map(function(index,input) {return '18:'+input.name;}).toArray();
DAPI.api.send({method: "users.getMappings",payload: {ids: ids},
callback: $.proxy(this.selectFriendsPt2, this)});
}
else {
var maxNeeded = _Toolbar.get(_Toolbar.ActiveFriendsNum,20);
var ap = new ActiveFriends(this.getFbuid(), this.findAppId());
var mostActive = ap.mostActive();
var numFound = 0;
for (var i=0, numFound=0;i < mostActive.length && numFound < maxNeeded; ++i) {
var fbuid = mostActive[i];
var selected = inputs.filter('[name="' + fbuid + '"]');
if (selected.length > 0) {
selected.click();
++numFound;
}
}
var statusStr = numFound > 0 ? (numFound + ' added!') :
'No (more) active friends found on this list (try the "All Friends" tab, if present)';
this.showStatus(document.body, statusStr);
}
},
selectFriendsPt2: function(r) {
function findInputWithValue(inputs, fbuid) {
for(var i=0;i<inputs.length;++i) {
var input = inputs[i];
if (r['18:'+input.name][1] == fbuid) {return input;}
}
return null;
}

var inputs = $('.zui_listselector_dual_unselected_item input').
not('.zui_listselector_dual_unselected_item_hidden input');
if (inputs.length > 0) {
var ap = new ActiveFriends(this.getFbuid(), this.findAppId());
var mostActive = ap.mostActive();
var mostActiveInList = mostActive.filter(function(fbuid) {return findInputWithValue(inputs, fbuid);});
var mostActiveToSelect = mostActiveInList.slice(0,_Toolbar.get(_Toolbar.ActiveFriendsNum,20));
for(var i=0;i<mostActiveToSelect.length;++i) {
var input = findInputWithValue(inputs, mostActiveToSelect[i]);
if (input) {input.click();}
}
var statusStr = mostActiveToSelect.length > 0 ? (mostActiveToSelect.length + ' added!') :
'No (more) active friends found on this list (try the "All Friends" tab, if present)';
this.showStatus(document.body, statusStr);
}
},
setDefaultNumFriends: function() {
var selectInputs = $("select.gu_num_friends");
var defaultVal = _Toolbar.get(_Toolbar.ActiveFriendsNum, 20);
selectInputs.attr({value:defaultVal});
selectInputs.change(function(e) {_Toolbar.put(_Toolbar.ActiveFriendsNum, $(this).val());});
}
};

var _InsideFB = {
replaceUrlPrefix: function(html) {
var isSecure = document.location.protocol == 'https:';
return html.replace(/@urlprefix@/g,
isSecure ? 'https://gamersunite.coolchaser.com' : 'http://assets.gamersunite.com');
},
replaceUrlProtocol: function(url) {
if (document.location.protocol == 'https:') {
return url.replace(/^http:/, 'https:');
}
return url;
},
insertStylesheet: function(url) {
url = this.replaceUrlPrefix(url);
var linkElt = document.createElement('link');
linkElt.type = 'text/css';
linkElt.rel = 'stylesheet';
linkElt.media = 'screen';
linkElt.href = url;
document.getElementsByTagName('head')[0].appendChild(linkElt);
},
isFBUri: function(uri) {
var locHash = location.hash;
var match = locHash.indexOf('#!' + uri) == 0;
if (!match) {
var escapedUri = uri.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
match = new RegExp("www\.facebook\.com" + escapedUri).test(location.href);
}
return match;
}
};
function TimedContinuation(func, maxTime) {
this.func = func;
this.maxTime = maxTime != null ? maxTime : 3000;
this.done = false;
window.setTimeout(this.doIt.bind(this), this.maxTime);
}

TimedContinuation.prototype.doIt = function() {
if (!this.done) {
this.done = true;
return this.func();
}
};

function MultiUrlOpener(urls, options) {
options = options || {};
this.stepCB = options.stepCB;
this.stepEndCB = options.stepEndCB;
this.finalCB = options.finalCB;
this.delay = options.delay || 10000;
var leftOffset = options.leftOffset || 20;
var topOffset = options.topOffset || 50;
this.specs = options.windowSpecs ||
"width=640,height=500, left=" + ((window.screenLeft||window.screenX)+leftOffset) + ",top=" +
((window.screenTop||window.screenY)+topOffset);
this.urls = urls;
this.index = 0;
}

MultiUrlOpener.prototype = {
start: function() {
var firstUrl = this.urls.shift();
if (firstUrl) {
this.popupWindow = window.open(firstUrl,'',this.specs);
if (this.stepCB) {this.stepCB(0);}
this.timer = window.setInterval(this.next.bind(this), this.delay);
++this.index;
}
},
next: function() {
var url = this.urls.shift();
if (!this.popupWindow.closed && url) {
this.popupWindow.location = url;
if (this.index > 0 && this.stepEndCB) {this.stepEndCB(this.index-1);}
if (this.stepCB) {this.stepCB(this.index);}
++this.index;
}
else {
this.popupWindow.close();
window.clearInterval(this.timer);
if (this.finalCB) {this.finalCB();}
}
}
};
var _gu_debug = false;
var _AutoAccepter = {
Version: '0.93',
AccepterClass: 'gu_module',
WaitId: 'gu_wait',
FormAction: 'http://www.facebook.com/ajax/reqs.php?__a=1',
GU_Html: '<img src="@urlprefix@/images/holiday_gift.png" class=gu_present><div class=return_inner><h2>Return the favor to your neighbors via Gamers Unite! gift exchange!</h2><p>Send exactly what they want by returning gifts on their wishlist. No more returning the same gifts!</p><div class=gu_gift_btns><a href="http://gamersunite.coolchaser.com/games/farmville/friend_gift_requests" target=_blank class="gu_button gu_fv"><img src="@urlprefix@/images/icon_fv.png">Farmville Gift Exchange</a><a href="http://gamersunite.coolchaser.com/games/pioneer-trail/friend_gift_requests" target=_blank class="gu_button gu_ftv"><img src="@urlprefix@/images/icon_pt.gif">Pioneer Trail Gift Exchange</a></div></div>',
Intro_HTML: '<h2 class=gu_title>Gamers Unite! One-Click Gifts</h2><h3 class=gu_status id=gu_off>Your One-Click Gifts is turned off</h3><p>Accept all gift requests with only one click! (version @vers@)</p><ul class=gu_lists><li>Make sure you allow popups.</li><li>Does <strong>NOT</strong> work for any requests that requires another followup or games that you must accept in-game (such as The Sims Social, Mafia Wars2)</li><li>Tweak how many seconds you want to wait until we process the next gift by adjusting the dropdown next to the "Accept each gift in". This is useful for games that takes an extra long time to load to accept gifts.</li></ul><h2 class="gu_title gu_sec">Requests by Games</h2><ul id=_gu_list class=gu_games></ul>',
Accept_HTML: 'Success!<br /> <span class="but">Not in Game?<br />Click <a href="@url@" target="_blank">here</a>.</span>',
Invite_HTML2:'<div id=gu_overlay></div><div class=gu_generic_dialog><div class=gu_generic_dialog_popup><div class=gu_pop_container_advanced><div class=gu_pop_content><h2>We are accepting your gifts...<img src="@urlprefix@/images/ajax-loader-big.gif" alt="please wait momentarily" class=gu_ajax></h2><div class=gu_pop_inner><div class=gu_ajax></div><p><img src="@urlprefix@/images/friends.png" class=gu_friends><strong>Are you an active friend to others?</strong></p><p>Show up more on other people\'s active friends list so you\'ll get more gifts!</p><p>The more friends you have who use 1-Click Friends, the more helpful you are to others and the more gifts you\'ll receive!</p></div><div class="gu_clear gu_clearfix gu_dialog_buttons"><a href=" http://gamersunite.coolchaser.com/invites/new" target=_new>Invite More Friends</a><a onclick="_AutoAccepter.removeWaitBox()" class=gu_ignore>No Thanks.</a></div></div></div></div></div>',
COMPATVIEW_HTML:'<div class=gu_alert_inner><span>GAMERS UNITE! MESSAGE</span>: It looks like your Internet Explorer is in Compatibility View. 1-Click Gifts will NOT work well if this is turned on.<a href="http://gamersunite.coolchaser.com/topics/69652-gamers-unite-1-click-gifts-freezing-up-your-interenet-exlorer">Learn how to turn it off</a>.</div>',
init: function() {
try {
if (window.onloadRegister) {onloadRegister(this.bind(this.testPage));}
if (window.Arbiter) {Arbiter.subscribe('page_transition', this.bind(this.onPageTransition));}
}
catch (e) {if (window._gu_debug) {console.log(e);}}
},
onPageTransition: function() {
var existingCallback = PageTransitions._completionCallback;
var self = this;
PageTransitions.setCompletionCallback(function() {
try {
self.testPage();
if (existingCallback) {existingCallback();}
} catch(e) {if (window._gu_debug) {console.log(e);}}
});
},
testPage: function() {
if (_InsideFB.isFBUri('/reqs.php')) {
this.parseRequests();
}
else if (_InsideFB.isFBUri('/games') || _InsideFB.isFBUri('/?sk=apps')) {
this.parseGamePage();
}
},
checkCompatView: function() {
if (navigator.userAgent.match(/msie/i) && document.documentMode && document.documentMode < 8) {
var divElt = this.createElt('div', {klass:'gu_alert'});
divElt.innerHTML = this.COMPATVIEW_HTML;
document.body.insertBefore(divElt, document.body.firstChild);
}
},
isGUBar: function(tool) {
var toolids = ['60531', '60639', ', 62703', '62781', '62841'];
return (!toolids.indexOf || toolids.indexOf(tool.toolid));
},
isRequestPage: function() {
var hashStrs = location.href.split('#');
var match = hashStrs[1] && hashStrs[1].indexOf('!/reqs.php') == 0;
if (!match && !this.matchedDomain) {
match = location.href.match(/www\.facebook\.com\/reqs\.php/);
this.matchedDomain = true;
}
return match;
},
applicableConfBox: function(confBox) {
return true; //!confBox.innerHTML.match(/actions\[accept\]/);
},
scrollToElt: function(elt) {
var selectedPosY = 0;
while(elt != null){
selectedPosY += elt.offsetTop;
elt = elt.offsetParent;
}
window.scrollTo(0,selectedPosY);
},
createSidebarElt: function(confBox, header) {
if (this.requestBoxElt) {
try {
var numRequests = DOM.scry(confBox,'li.uiListMedium').length;
var linkText = numRequests + ' ' + header.innerHTML;
var linkElt = this.createElt('a', {onclick:this.bind(this.scrollToElt, header),
klass:'request_link UIImageBlock_Content UIImageBlock_ICON_Content', text:linkText});
var sidebarElt = this.createElt('div', {klass:'UIImageBlock clearfix UIRequestBox_Request UIRequestBox_RequestSecond',
kids:[linkElt]});
this.requestBoxElt.appendChild(sidebarElt);
}
catch(e) {if (window._gu_debug) {console.log(e);}}
}
},
insertIntro: function(isOn) {
try {
if (this.requestBoxElt) {
var introDiv = this.createElt('div', {klass:'gu_module'});
var html = this.Intro_HTML.replace('@vers@', this.Version);
introDiv.innerHTML = _InsideFB.replaceUrlPrefix(html);
this.requestBoxElt.insertBefore(introDiv, this.requestBoxElt.childNodes[0]);
}
}
catch(e) {if (window._gu_debug) {console.log(e);}}
},
continueAfterPageInit: function() {
var alreadyParsed = DOM.scry(document, '.'+this.AccepterClass).length > 0;
if (alreadyParsed) {
return false;
}
else {
var isOn = !this.isOff;
this.insertStylesheet();
this.requestBoxElt = DOM.scry(document, '#rightCol')[0] || DOM.scry(document,'div.UIRequestBox')[0];
this.insertIntro(isOn);
this.checkCompatView();
this.parseAttempts = 0;
return isOn;
}
},
addGamePageButtons: function() {
function getGameTitleFromConfBox(confBox) {
return DOM.getText(DOM.find(confBox, 'a strong')) || 'unknown';
}

function createTimeElt() {
var options = [5,10,15,20,25,30,45,60].map(
function(val) {return $N('option', {value:val}, _tx(val + ' secs'));});
options[1].selected = 'selected';
return $N('select', {className:'gu_time'}, options);
}

var confBoxes = DOM.scry(document, 'div.appRequestGroup');
if (confBoxes.length == 0) {
++this.parseAttempts;
if (this.parseAttempts < 8) {
window.setTimeout(this.addGamePageButtons.bind(this),Math.pow(2,thisparseAttempts)*25);
}
return;
}
var gameListDiv = $('_gu_list');
var gameListTitles = [];
for (var i=0; i<confBoxes.length; ++i) {
var confBox = confBoxes[i];
var timeElt = createTimeElt();
var acceptAllElt = this.createElt('a', {klass:'gu_button', href:'javascript:void(0)',
onclick:this.bind(this.autoAccept,confBox, timeElt), text:'Accept All'});
var guActionsDiv = $N('div', {className:'gu_actions'},
[_tx('Accept each gift in '), timeElt, _tx(' '), acceptAllElt]);
var gameTitle = getGameTitleFromConfBox(confBox);
var h4Elt = $N('h4', {className:'gu_game_title'}, [_tx("Requests from " + gameTitle),
guActionsDiv]);
DOM.prependContent(confBox, h4Elt);
if (gameListDiv) {
var idStr = escape(gameTitle);
var anchorElt = $N('a', {id:idStr, name:idStr});
DOM.prependContent(confBox,anchorElt);
gameListTitles.push(gameTitle);
}
this.findActiveFriends(confBox);
}
if (gameListDiv) {
gameListTitles.sort();
gameListTitles.each(function(gameTitle) {
var idStr = escape(gameTitle);
gameListDiv.appendChild($N('li',{},$N('a', {href:'#'+idStr},_tx(gameTitle + ' requests'))));
});
}
},
parseGamePage: function() {
if (this.continueAfterPageInit()) {
this.addGamePageButtons();
}
},
parseRequests: function() {
if (this.continueAfterPageInit()) {
var confBoxes = DOM.scry(document,'#contentArea div.mbl');
var headers = [];
for (var i=0; i<confBoxes.length; ++i) {
var confBox = confBoxes[i];
if (this.applicableConfBox(confBox)) {
var acceptAllElt = this.createElt('a',
{klass:'gu_button', href:'javascript:void(0)', onclick:this.bind(this.autoAccept,confBox), text:'Accept All'});
divElt = this.createElt('div', {klass:'gu_actions', kids:[acceptAllElt]});
var header = DOM.scry(confBox, 'h3.uiHeaderTitle')[0];
if (header) {
header.appendChild(divElt);
}
this.findActiveFriends(confBox);
}
}
}
},
insertStylesheet: function() {
_InsideFB.insertStylesheet("@urlprefix@/stylesheets/autoaccept.css");
},
bind: function(func) {
var args = Array.prototype.slice.call(arguments);
args.shift(); //remove func
var self = this;
return function() {return func.apply(self, args);};
},
insert_html: function(confDiv) {
try {
var header = DOM.find(confDiv, 'h3.uiHeaderTitle') || DOM.find(confDiv, 'h4.gu_game_title');
var divElt = this.createElt('div', {klass:'return_gift'});
divElt.innerHTML = _InsideFB.replaceUrlPrefix(this.GU_Html);
DOM.insertAfter(header, divElt);
}
catch(e) {}
},
giftable: function(confDiv) {
var match = confDiv.innerHTML.match(/app_(\d+)/);
return match && (match[1] == '102452128776' || match[1] == '201278444497');
},
getFbuid: function() {
return Env.user;
},
parseActiveFriends: function() {
if (_InsideFB.isFBUri('/games')) {
var confBoxes = DOM.scry(document, 'div.appRequestGroup');
var self = this;
confBoxes.forEach(function(cb) {self.findActiveFriends(cb);});
}
},
findActiveFriends: function(confDiv) {
function getInputValue(form, idStr) {
var inputs = DOM.scry(form, 'input');
for(var i=0;i<inputs.length;++i) {
if (inputs[i].id == idStr) {return inputs[i].value;}
}
return null;
}

if (!_Toolbar.inited()) {return;}
try {
confDiv = confDiv.nextSibling;
var forms = DOM.scry(confDiv, '.uiList form');
if (forms.length > 0) {
var appId = getInputValue(forms[0], 'params[app_id]');
var ap = new ActiveFriends(this.getFbuid(), appId);
if (appId) {
var friendInfos = forms.map(function(f) {
return {fbuid:getInputValue(f, "params[from_id]"), source:'request'};});
ap.addFriendsSync.apply(ap, friendInfos);
}
}
}
catch(e) {
_Toolbar.log('findActiveFriends error: ' + e);
}
},
expandConfBox: function(confBox) {
try {
var mainUL = DOM.find(confBox, 'ul.uiCollapsedListHidden');
if (mainUL) {
CSS.removeClass(mainUL, 'uiCollapsedListHidden');
CSS.addClass(mainUL, 'uiCollapsedListVisible');
}
} catch (e) {
_Toolbar.log('1-click-gifts expandConfBox err: ' + e);
}
},
autoAccept: function(confDiv, timeElt) {
confDiv = confDiv.nextSibling;
this.expandConfBox(confDiv);
var forms = DOM.scry(confDiv, 'form');
if (this.giftable(confDiv)) {this.insert_html(confDiv);}
var self = this;
var requestUrls = [];
var validForms = [];
for(var i=0; i<forms.length;++i) {
forms[i].confBox = confDiv;
var url = a.extractUrl(forms[i]);
if (url) {
requestUrls.push(url);
validForms.push(forms[i]);
forms[i].statusElt = this.getStatusElt(forms[i]);
}
}
if (validForms.length > 0) {
new MultiUrlOpener(requestUrls, {
stepCB: function(i) {
self.acceptForm(validForms[i]);
self.showAccepted(validForms[i-1], requestUrls[i-1]);
},
finalCB: function() {
var lastIndex = validForms.length-1;
self.showAccepted(validForms[lastIndex], requestUrls[lastIndex]);
},
delay: (timeElt && timeElt.value*1000) || 10000
}).start();
}
},
getStatusElt: function(form) {
return DOM.scry(form, 'div.mtm')[0] || DOM.scry(form, 'ul')[0];
},
extractUrl: function(form) {
var url;
var isRequest2 = !!form.innerHTML.match(/actions\[accept\]/);
if (isRequest2) {
var links = DOM.scry(form.confBox.previousSibling, 'a.pts');
url = links.length > 0 && links[0].href;
var requestId = form.id && form.id.value;
if (url && requestId) {
url += url.indexOf('?') > 0 ? '&' : '?';
url += 'request_ids=' + requestId;
return url;
}
}
else {
for (var i=0; i<form.length;++i) {
var formElt = form[i];
if (formElt.type == 'submit' && formElt.name.match(/actions\[http/)) {
var match = formElt.name.match(/^actions\[([^\]]*)\]$/);
return match && match[1];
}
}
}
return null;
},
acceptForm: function(form) {
var actionUrl = form.action;
var hashStr = '';
for (var i=0; i<form.length; ++i) {
if (form[i].type != 'submit' && form[i].name != 'actions[reject]') {
hashStr += '&' + encodeURIComponent(form[i].name) + '=' + encodeURIComponent(form[i].value);
}
}
hashStr = hashStr.slice(1); //get rid of first &
this.sendAsyncRequest(actionUrl, hashStr);
this.showProcessing(form);
},
processRequest2: function(form, continuation) {
var links = DOM.scry(form.confBox, 'a.pts');
var url = links.length > 0 && links[0].href;
var requestId = form.id && form.id.value;
if (url && requestId) {
url += url.indexOf('?') > 0 ? '&' : '?';
url += 'request_ids=' + requestId;
var divStatusElt = this.getStatusElt(form);
this.showProcessing(divStatusElt);
this.openRequest(url, divStatusElt, continuation);
}
else {continuation();}
},
processForm: function(form, doIgnore, continuation) {
var isRequest2 = !!form.innerHTML.match(/actions\[accept\]/);
if (!doIgnore && isRequest2) {return this.processRequest2(form, continuation);}

var hash = {};
var acceptInput = null;
var url;
for(var i=0; i<form.length;++i) {
var formElt = form[i];
if (formElt.type == 'submit') {
if (formElt.name.match("apps.facebook.com")) {
var match = formElt.name.match(/^actions\[([^\]]*)\]$/);
if (match) {
acceptInput = formElt;
url = match[1];
}
}
}
else {
hash[formElt.name] = formElt.value;
}
}
if (acceptInput || doIgnore) {
var hashStr = '';
if (doIgnore) {hash['actions[reject]'] = 'Ignore';}
else {hash[acceptInput.name] = acceptInput.value;}
for (var key in hash) {
hashStr += '&' + encodeURIComponent(key) + '=' + encodeURIComponent(hash[key]);
}
hashStr += '&post_form_id_source=AsyncRequest';
hashStr = hashStr.slice(1); //get rid of first &
var divStatusElt = this.getStatusElt(form);
this.showProcessing(divStatusElt);
var func = doIgnore ? this.bind(this.showIgnored, form) : null;
var formUrl = isRequest2 ? form.action : _InsideFB.replaceUrlProtocol(this.FormAction);
this.sendAsyncRequest(formUrl, hashStr, func);
if (doIgnore) {
continuation();
}
else {
this.openRequest(url, divStatusElt, continuation);
}
}
else {continuation();}
},
showStatus: function(divStatusElt, statusElt) {
if (divStatusElt) {
divStatusElt.innerHTML = '';
divStatusElt.appendChild(statusElt);
}
},
showProcessing: function(form) {
if (form) {
var divStatusElt = this.getStatusElt(form);
var processingDiv = this.createElt('div', {klass:'gu_process', kids:[
this.createElt('img', {src:_InsideFB.replaceUrlPrefix('@urlprefix@/images/ajax-loader.gif'),
style:"vertical-align:middle; margin-right:3px"}),
document.createTextNode(' Processing...')]});
this.showStatus(divStatusElt, processingDiv);
}
},
showIgnored: function(form) {
var ignoredDiv = this.createElt('div', {klass:'gu_process', text:'Ignored!'});
form.innerHTML = '';
form.appendChild(ignoredDiv);
},
showAccepted: function(form, url) {
if (form) {
var divStatusElt = this.getStatusElt(form);
var acceptedDiv = this.createElt('div', {klass:'gu_process'});
acceptedDiv.innerHTML = this.Accept_HTML.replace('@url@', url);
this.showStatus(divStatusElt, acceptedDiv);
}
},
addWaitBox: function() {
if (_Toolbar.get(_Toolbar.LastPopupKey,0) < (Date.now()-86400000)) {
var div = $N('div', {id:this.WaitId});
div.innerHTML = _InsideFB.replaceUrlPrefix(this.Invite_HTML2);
document.body.appendChild(div);
_Toolbar.put(_Toolbar.LastPopupKey,Date.now());
}
},
removeWaitBox: function() {
var div = $(this.WaitId);
if (div) {document.body.removeChild(div);}
},
sendAsyncRequest: function(url, data, func) {
var req = new XMLHttpRequest();
dat = data; x= req;
req.open('POST', url);
req.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
if (func) {req.onreadystatechange = func;}
req.send(data);
},
createElt: function(tagName, options) {
        var elt = document.createElement(tagName);
        if (options) {
         for(var prop in options) {
         if (prop.match(/style/)) {elt.setAttribute(prop, options[prop]);}
         else if (prop == 'text') {elt.innerHTML = options[prop];}
         else if (prop == 'klass') {elt.setAttribute('class', options[prop]); elt.className = options[prop];}
         else if (prop == 'kids') {
         for (var i=0; i< options.kids.length; ++i) {elt.appendChild(options.kids[i]);}
         }
         else {elt[prop] = options[prop];}
                }
        }
        return elt;
},
openRequest: function(url, divStatusElt, continuation) {
var self = this;
url = _InsideFB.replaceUrlProtocol(url);
var iframe = this.createElt('iframe', {src:url, style:"width:10px;height:10px;"});
var timeoutTC = new TimedContinuation(function(e) {
self.showAccepted(divStatusElt, url);
window.setTimeout(function() {document.body.removeChild(iframe);}, 5000);
continuation();
}, 25000);
var onloadFn = timeoutTC.doIt.bind(timeoutTC);
if (iframe.attachEvent) {iframe.attachEvent('onload', onloadFn);}
else {iframe.onload = onloadFn;}
document.body.appendChild(iframe);
},
turnOff: function() {
if (_InsideFB.isFBUri('/reqs.php') ||_InsideFB.isFBUri('/games') || _InsideFB.isFBUri('/?sk=apps')) {
this.isOff = true;
DOM.scry(document,'.gu_button').forEach(function(btn) {btn.style.display = 'none';});
if ($('gu_off')) {$('gu_off').style.display = 'block';}
}
}
};
var a = _AutoAccepter;
_AutoAccepter.init();

function ToolBarInit(tool) {
_tt = tool;
if (_Toolbar.isGUBar(tool)) {
_Toolbar.init(tool);
_AutoAccepter.parseActiveFriends();
if (_ActiveFriendsSelector.isFriendsSelector()) {
onloadRegister(_ActiveFriendsSelector.inject.bind(_ActiveFriendsSelector));
}
if (_ActiveFriendsZ.isFriendsSelector()) {
_ActiveFriendsZ.inject();
}
if (tool && tool.GetVariable('unauto_accept')) {
_AutoAccepter.turnOff();
}
}

 
 

查询:url=http://gamersunite.coolchaser.com/toolbar/fb_request_page

 
 

 
 

技术资料

2012年2月22日

21:11

 
 

Firefox

2012年2月24日

21:12

 
 

以后有时间,将firefox.js的前面一些替换成自己的url

 
 

创建弹出窗口

2012年3月12日

21:18

 
 

 
 

具有弹出窗口的按钮:

<toolbarbutton id="MMOSITE_TOOLBAR_STEP1_GIFTS" label="Gifts"

image="http://cdn.nextsmallthings.com/tbar/mouse.png"

popup="gifts_mainPanel" />

 
 

弹出窗口:

<panel id="gifts_mainPanel">

<vbox class="alert-container" flex="1">

<hbox>

<checkbox onclick="MMOSITE_TOOLBAR_STEP1.onPopupPaneCheckAllClick(this,event,'gifts_req_container');" />

<button label="Accept" onclick="MMOSITE_TOOLBAR_STEP1.onPopupPaneGiftsAcceptClick(this,event);"/>

</hbox>

<spacer/>

<richlistbox id="gifts_req_container" class="list" flex="1" height="150" >

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

<richlistitem ><hbox><checkbox/><label value="(50)"/></hbox></richlistitem>

</richlistbox>

</vbox>

</panel>

 
 

菜单

2012年3月12日

21:17

 
 

https://developer.mozilla.org/en/XUL/PopupGuide/MenuItems

 
 

菜单的checkbox好像只是个钩,不能点击.所以要改为原来的checkbox.

 
 

Json

2012年3月4日

16:02

 
 

解析字符串到对象:

JSON.parse(usersstring)

 
 

处理对象成字符串:

JSON.stringify(user)

 
 

数组解析成字符串,以,分隔:

users.join(',')

 
 

创建弹出菜单

2012年3月1日

20:11

 
 

var button = document.getElementById('MMOSITE_TOOLBAR_STEP1_PLAY');

var menu_popup = document.createElement("menupopup");

while(button.childNodes.length>0)

        button.removeChild(button.childNodes[i]);

        
 

for(var i=0;i<data.length;++i){

        // name image url

        var menuitem = document.createElement("menuitem");

menuitem.setAttribute("class", "menuitem-iconic");

menuitem.setAttribute("label", data[i].name);

menuitem.setAttribute("image", data[i].image);

menuitem.setAttribute("url", data[i].url);

menuitem.setAttribute("cmd", "redirect");

menupopup.appendChild(menuitem);

}

// menu_popup.setAttribute("onpopupshowing", "FC_Chevronafe43e800abc4df281a03fe44b74abe8.UpdateMenu(event);");

button.appendChild(menu_popup);

 
 

ajax请求

2012年3月1日

20:03

 
 

var req = Components.classes["@mozilla.org/xmlextras/xmlhttprequest;1"]

.createInstance(Components.interfaces.nsIXMLHttpRequest);

req.onreadystatechange = function(e)

{

try

{

if (req.readyState != 4) { return; }


 

debug("finished graph post, status = " + req.status);

debug("graph response: " + req.responseText);

 
 

/*if (req.status == 400)

{

fbSvc.sessionEnd();

}*/

 
 

if (req.status != 200)

{

return;

}

 
 

var jsObject = JSON.parse(req.responseText);

 
 

callback(jsObject);

}

catch (e)

{

debug("graph error: " + e);

return;

}

 
 

};

 
 

var url = "https://graph.facebook.com/" + method;

var data = "access_token=" + this._accessToken;

debug("going to POST to '" + url + "' with data = '" + data + "'");

 
 

req.open("POST", url, true);

req.send(data); // 如果data=null,也要发送,不然里面req.readyState不会等于4

 
 

计时器

2012年3月1日

20:01

 
 

this._checker = {

notify: function(timer) {


 

}

};


 

var timer = Cc['@mozilla.org/timer;1'].createInstance(Ci.nsITimer);

timer.initWithCallback(fbSvc._checker, BASE_CHECK_INTERVAL/10, Ci.nsITimer.TYPE_REPEATING_SLACK);

 
 

侧边栏?

2012年2月26日

13:45

 
 

<broadcasterset id="mainBroadcasterSet">

<broadcaster id="viewFacebookSidebar" autoCheck="false"

label="&toolbar.sidebar.label;"

type="checkbox" group="sidebar"

sidebarurl="chrome://facebook/content/sidebar.xul"

sidebartitle="&toolbar.sidebar.label;"

oncommand="toggleSidebar('viewFacebookSidebar');event.stopPropagation();" />

</broadcasterset>

 
 

工具条

2012年2月26日

13:07

 
 

可以使用 ff控制的工具条

<toolbar id="mm-facebook-toolbar"

class="chromeclass-toolbar-additional"

oldclass="chromeclass-toolbar"

mode="full"

iconsize="small"

customizable="true"

context="toolbar-context-menu"

toolbarname="&toolbar.facebook.name;"

crop="end"

defaultset="mm-facebook-login-info,mm-mmosite-info">

 
 

defaultset使用上面的:

 
 

 
 

component介绍

2012年2月26日

9:50

 
 

chrome.manifest

interfaces components/facebook.xpt

component {32CF52D4-6693-410B-A536-18D7CEB89450} components/facebook.js

contract @mmosite.com/facebook-service;1 {32CF52D4-6693-410B-A536-18D7CEB89450}

category profile-after-change Facebook @mmosite.com/facebook-service;1

 
 

 
 

 
 

xpt生成

2012年2月25日

20:55

 
 

(1)生成头文件

/usr/lib/mozilla-1.7.12/xpidl -m header -I/usr/share/idl/mozilla-1.7.12

testplug.idl

(2)生成xpt文件

/usr/lib/mozilla-1.7.12/xpidl -m typelib -I/usr/share/idl/mozilla-1.7.12

testplug.idl

 
 

源文档 <http://www.yunsec.net/a/special/linux/shell/2010/0227/2693_2.html>

 
 

Generating xpt on Windows

 
 

源文档 <https://developer.mozilla.org/en/XPIDL/Generating_xpt_on_Windows>

 
 

http://hyperstruct.net/2006/08/10/your-first-javascript-xpcom-component-in-10-minutes/

 
 

xulexplorer

2012年2月25日

17:36

 
 

http://starkravingfinkle.org/projects/xulexplorer/xulexplorer-1.0a1pre.en-US.win32.exe

 
 

Install.rdf

2012年2月24日

21:12

 
 

<!-- Firefox -->

<em:targetApplication>

<Description>

         <em:unpack>true</em:unpack>

<em:id>{ec8030f7-c20a-464f-9b0e-13a3a9e97384}</em:id>

<em:minVersion>2.0</em:minVersion>

<em:maxVersion>10.*</em:maxVersion>

</Description>

</em:targetApplication>

 
 

Em:id 一定要为这个

 
 

 
 

 
 

天铭接口

2012年2月24日

20:34

 
 

游戏接口

 
 

http://www.bbgsite.com/script/socialgames/cv_toolbar.js

 
 

var toolbar = [        {name:"CastleVille",img:"http://images.bbgsite.com/www/socialgames/app/castleville1.jpg",url:"http://www.appdata.com/apps/facebook/107040076067341-castleville"},
                                {name:"Bubble Witch Saga",img:"http://images.bbgsite.com/www/socialgames/app/bws.jpg",url:"http://appdata.com/apps/facebook/256051837747677-bubble-witch-saga"},
                                {name:"FarmVille",img:"http://images.bbgsite.com/www/socialgames/app/farmville.gif",url:"http://www.appdata.com/apps/facebook/102452128776-farmville"},
                                {name:"Tetris Battle",img:"http://images.bbgsite.com/www/socialgames/app/tetrisbattle.jpg",url:"http://www.appdata.com/apps/facebook/130409810307796-tetris-battle"},
                                {name:"Words With Friends",img:"http://images.bbgsite.com/www/socialgames/app/wwf.jpg",url:"http://www.appdata.com/apps/facebook/168378113211268-words-with-friends"},
                                {name:"Diamond Dash",img:"http://images.bbgsite.com/www/socialgames/app/diamonddash.jpg",url:"http://www.appdata.com/apps/facebook/127995567256931-diamond-dash"},
                                {name:"MagicLand",img:"http://images.bbgsite.com/www/socialgames/app/magicland.jpg",url:"http://www.appdata.com/apps/facebook/40343401983-magoc-land"}
                        ]

 
 

源文档 <http://www.bbgsite.com/script/socialgames/cv_toolbar.js>

 
 

 
 

 
 

Facebook

2012年2月22日

21:11

 
 

  1. Javascript sdk

1.1 Facebook for Firefox 插件

 
 

Git : https://github.com/facebook/firefox-toolbar

 
 

1.2 User

 
 

源文档 <http://developers.facebook.com/docs/reference/api/user/#apprequests>

 
 

 
 

?

notifications

 
 

源文档 <http://developers.facebook.com/docs/reference/api/user/>

 
 

 
 

 
 

1.3 UID 用户 调试对照表

 
 

100001862563169 liandeliang@yahoo.com.cn Lian deliang

100002627144445 416320079@qq.com Li Ku

100003091373140 h298905@163.com Azhe Huang

1729552298 bd@bbgsite.com Bao zi

 
 

账号:h298905@163.com

密码:1989523homer

账号:416320079@qq.com

密码:clj1014

帐号:bd@bbgsite.com

密码:ttyy44233333ye

 
 

 
 

 
 

 
 

 
 

App App_id

pkrss_web 300106523381410

 
 

 
 

1.4 查询所有别人邀请的请求

 
 

http://developers.facebook.com/docs/reference/rest/notifications.get/

 
 

{
"messages": {
"unread": 0,
"unseen": 0,
"most_recent": 0
},
"pokes": {
"unread": 0,
"most_recent": 0
},
"shares": {
"unread": 0,
"most_recent": 0
},
"notification_counts": {
"unseen": 0
},
"friend_requests_counts": {
"unread": 1,
"unseen": 1
},
"friend_requests": [
100002627144445
],
"group_invites": [],
"event_invites": []
}

 
 

源文档 <http://developers.facebook.com/docs/reference/rest/notifications.get/>

 
 

https://api.facebook.com/method/notifications.get?access_token=AAAEQ8f64jqIBAIcc0xIagwZAEBMwcq9LEBL3LocCa9l4ZBHrtO2cRg5gR8co7lG90ZCDxp3gHqcCeUY6xbHRa22PIJDRTzjOmyOak8j3TEexVxivFyj&format=json

 
 

{

  "data": [

    {

      "id": "notif_1729552298_17031359",

      "from": {

        "name": "Helios D AL Ma'shumovic",

        "id": "100002294894347"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T12:40:10+0000",

      "updated_time": "2012-02-29T12:40:10+0000",

      "title": "Helios D AL Ma'shumovic, Bayram Ünsal and 79 others sent you requests in Empires & Allies.",

      "link": "http://apps.facebook.com/empiresandallies/?request_ids=140955106027091\u00252C375087592519488\u00252C335892453119183\u00252C277536792315078\u00252C195198517250755\u00252C162403630545028\u00252C161185864001011\u00252C120479674747426\u00252C377361232274988\u00252C228053103957832\u00252C335025853201458\u00252C164465960338542\u00252C357576387609781\u00252C304511752943484\u00252C287279324678094\u00252C328923660491678\u00252C179886735458095\u00252C124100137715775\u00252C384159881611739\u00252C186575891450747\u00252C399860460030245\u00252C381619131849866\u00252C179209745527052\u00252C182297788549944\u00252C381765511834153\u00252C380183335326535\u00252C307390629316356\u00252C194309330674556\u00252C252665388150650\u00252C263549183721397\u00252C402017236491220\u00252C240409239387311\u00252C276562712412853\u00252C331366693566223\u00252C305652962833025\u00252C374671589224066\u00252C280887715318374\u00252C278953115507867\u00252C252476881503974\u00252C330305643673325\u00252C282483611821995\u00252C119944068133784\u00252C373277959362592\u00252C150745708379364\u00252C392793947414260\u00252C316105435105037\u00252C242681009155281\u00252C182628141847322\u00252C381283078566003\u00252C311295902263725&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Empires & Allies",

        "canvas_name": "empiresandallies",

        "namespace": "empiresandallies",

        "id": "164285363593426"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17031837",

      "from": {

        "name": "Naciye Nazlıgider",

        "id": "100002288628239"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T12:34:06+0000",

      "updated_time": "2012-02-29T12:34:06+0000",

      "title": "Naciye Nazlıgider, Phoebe Ting and 8 others sent you requests in Bubble Witch Saga.",

      "link": "http://apps.facebook.com/bubblewitch/?request_ids=181825858597231\u00252C192013327570405\u00252C176121879166318\u00252C341432195895380\u00252C379537222075566\u00252C255494234533423\u00252C246845418736134\u00252C100216730108960\u00252C350862694947243\u00252C305035656223809\u00252C249783385105766\u00252C294821317249978\u00252C186263118143670\u00252C333775423335515\u00252C302732199780389\u00252C308857952506878&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Bubble Witch Saga",

        "canvas_name": "bubblewitch",

        "namespace": "bubblewitch",

        "id": "256051837747677"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17025935",

      "from": {

        "name": "Michelle Tyler",

        "id": "100000715838640"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T12:33:58+0000",

      "updated_time": "2012-02-29T12:33:58+0000",

      "title": "Michelle Tyler, Simona Sartori and 113 others sent you requests in CastleVille.",

      "link": "http://apps.facebook.com/playcastleville/?request_ids=311809135546085\u00252C308024509258700\u00252C353436811362655\u00252C189051524536609\u00252C244314725660167\u00252C356612307711622\u00252C371685582855595\u00252C166972800086416\u00252C119543531506432\u00252C180298982083740\u00252C335986916445124\u00252C247578651997116\u00252C302862963111890\u00252C397230196959513\u00252C280397202030671\u00252C313784918678309\u00252C179476295499431\u00252C398844220141415\u00252C281801118560320\u00252C250931214991572\u00252C333656966680456\u00252C305717616157431\u00252C250489428372531\u00252C163425427110561\u00252C367285163293813\u00252C239457052814674\u00252C150712818383319\u00252C119613841500536\u00252C309924019068780\u00252C187152021388433\u00252C395393863807877\u00252C255192551228863\u00252C344466775592019\u00252C188419167933278\u00252C230427963720392\u00252C362010013833611\u00252C187557258019778\u00252C247553768665392\u00252C124641577661661\u00252C361989177167676\u00252C246915995394666\u00252C181536801959037\u00252C284473974956726\u00252C139591409497338\u00252C396524103694677\u00252C308219215900389\u00252C219942104770278\u00252C396872027005229\u00252C186992624737472\u00252C193421437430658&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "CastleVille",

        "canvas_name": "playcastleville",

        "namespace": "playcastleville",

        "id": "107040076067341"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17052471",

      "from": {

        "name": "Tessa Joves",

        "id": "1385993763"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T12:32:56+0000",

      "updated_time": "2012-02-29T12:32:56+0000",

      "title": "Tessa Joves, Rüzgar Mercan and 14 others sent you requests in The Sims Social.",

      "link": "http://apps.facebook.com/thesimssocial/?request_ids=201345769966957\u00252C332752820108284\u00252C248398088580068\u00252C386959308000038\u00252C357862514247823\u00252C119547824839272\u00252C218818991549370\u00252C193096344127847\u00252C179174148863007\u00252C247660658656080\u00252C217541531677989\u00252C356690667703941\u00252C229729487122657\u00252C351600211537277\u00252C357495690949529\u00252C119386778189717\u00252C242093712550202\u00252C320723067977573\u00252C397111223636573\u00252C194627050643535\u00252C382666821744535\u00252C300576090008008\u00252C339203179454623\u00252C140539122735220\u00252C367630303262316&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "The Sims Social",

        "canvas_name": "thesimssocial",

        "namespace": "thesimssocial",

        "id": "144959615576466"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17066014",

      "from": {

        "name": "Paul Taylor",

        "id": "100001778428544"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T12:27:51+0000",

      "updated_time": "2012-02-29T12:27:51+0000",

      "title": "Paul Taylor, Marti Mcfly and 9 others sent you requests in CityVille.",

      "link": "http://apps.facebook.com/cityville/?request_ids=359792667387511\u00252C189563997818699\u00252C345793178798837\u00252C331567480227102\u00252C278633028872317\u00252C356066957766568\u00252C305118516219344\u00252C100448363418652\u00252C100470510083349\u00252C231083606987306\u00252C332995556738278\u00252C252736218145255\u00252C228156373946939\u00252C333573863360234\u00252C183851975059240\u00252C181008132010088\u00252C338812452829026&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "CityVille",

        "canvas_name": "cityville",

        "namespace": "cityville",

        "id": "291549705119"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17066859",

      "from": {

        "name": "Joseph George",

        "id": "100002864374571"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T12:02:25+0000",

      "updated_time": "2012-02-29T12:02:25+0000",

      "title": "Joseph George, Mannathoor Wilson and Ameer Kallumpuram posted in DYFI.",

      "link": "http://www.facebook.com/groups/girishaj/260491377365191/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17068175",

      "from": {

        "name": "Bucko Williams",

        "id": "1365364295"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T11:59:09+0000",

      "updated_time": "2012-02-29T11:59:09+0000",

      "title": "Bucko Williams, Norma Bartlett and Daniel Odling sent you requests in Slotomania - Slot Machines.",

      "link": "http://apps.facebook.com/slotomania/?request_ids=281639375238088\u00252C238504919577057\u00252C195919803848117&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Slotomania - Slot Machines",

        "canvas_name": "slotomania",

        "namespace": "slotomania",

        "id": "169545139744270"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17037227",

      "from": {

        "name": "Ashley Tan",

        "id": "100002485972846"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T11:48:14+0000",

      "updated_time": "2012-02-29T11:48:14+0000",

      "title": "Ashley Tan and Yassine Sims posted in The sims social.",

      "link": "http://www.facebook.com/groups/simsfamly/265110476898475/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17067472",

      "from": {

        "name": "Ann Sweet",

        "id": "1764295161"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T11:41:17+0000",

      "updated_time": "2012-02-29T11:41:17+0000",

      "title": "Ann Sweet sent you a request in Diamond Dash.",

      "link": "http://apps.facebook.com/diamonddash/?request_ids=196220953817455\u00252C333023106734856&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Diamond Dash",

        "canvas_name": "diamonddash",

        "namespace": "diamonddash",

        "id": "127995567256931"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17069748",

      "from": {

        "name": "Biju Pappinisseri",

        "id": "100001822900457"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T11:34:42+0000",

      "updated_time": "2012-02-29T11:34:42+0000",

      "title": "Biju Pappinisseri added you to the group BEAUTIFUL !!!",

      "link": "http://www.facebook.com/groups/332778980097885/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17069646",

      "from": {

        "name": "Chee Eek",

        "id": "100002474507100"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T11:27:53+0000",

      "updated_time": "2012-02-29T11:27:53+0000",

      "title": "Chee Eek sent you a request in 開心水族箱.",

      "link": "http://apps.facebook.com/happyfishbowl/?request_ids=375378459146847&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "開心水族箱",

        "canvas_name": "happyfishbowl",

        "namespace": "happyfishbowl",

        "id": "215779025017"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17068301",

      "from": {

        "name": "Zainul Abid Bava",

        "id": "100002383615496"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T11:17:36+0000",

      "updated_time": "2012-02-29T11:17:36+0000",

      "title": "Zainul Abid Bava posted in BEST..FRIENDS....",

      "link": "http://www.facebook.com/groups/132954416824935/151707528282957/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17068331",

      "from": {

        "name": "Pu Kamolwan",

        "id": "1037639951"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T11:17:12+0000",

      "updated_time": "2012-02-29T11:17:12+0000",

      "title": "Pu Kamolwan, Albert Emler and 8 others sent you requests in Hidden Chronicles.",

      "link": "http://apps.facebook.com/hidden-chronicles/?request_ids=249666228452792\u00252C307916675928041\u00252C186024771508070\u00252C260807937326843\u00252C284706374931711\u00252C288917201174623\u00252C197190580380433\u00252C183173831792720\u00252C332749686761167\u00252C334291389956397\u00252C313100252079368\u00252C251919451560551\u00252C308894705831452\u00252C306403589415596\u00252C342032229172075\u00252C328463620533538&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Hidden Chronicles",

        "canvas_name": "hidden-chronicles",

        "namespace": "hidden-chronicles",

        "id": "100333333405439"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17048047",

      "from": {

        "name": "Che Pallam Uduma",

        "id": "100003402695833"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T11:15:07+0000",

      "updated_time": "2012-02-29T11:15:07+0000",

      "title": "Che Pallam Uduma, Philip John and 6 others posted in REPORTER.",

      "link": "http://www.facebook.com/groups/144116732374994/152489058204428/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17047752",

      "from": {

        "name": "Zainul Abid Bava",

        "id": "100002383615496"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T11:14:31+0000",

      "updated_time": "2012-02-29T11:14:31+0000",

      "title": "Zainul Abid Bava, Rasheemullan Poochi and 3 others posted in Tip-Top.",

      "link": "http://www.facebook.com/groups/176264395810333/185184621584977/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17051277",

      "from": {

        "name": "Giorgos Sorotos",

        "id": "1374180946"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T10:34:31+0000",

      "updated_time": "2012-02-29T10:34:31+0000",

      "title": "Giorgos Sorotos, Grace Kelly and 14 others sent you requests in FarmVille.",

      "link": "http://apps.facebook.com/onthefarm/?request_ids=357071417660693\u00252C185565668219285\u00252C377828325562633\u00252C183477625095348\u00252C182109825233691\u00252C173496996099503\u00252C279305968809324\u00252C373703315982978\u00252C218312128268077\u00252C309187515804948\u00252C394174283941807\u00252C193650437408235\u00252C163803220404574\u00252C339999962709597\u00252C333072576729842\u00252C241605282596352\u00252C370253932992540\u00252C328503637196345\u00252C181306335315459\u00252C377057328974059\u00252C152107954910242\u00252C313160242067140\u00252C241224402634200\u00252C177973982314644&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "FarmVille",

        "canvas_name": "onthefarm",

        "namespace": "onthefarm",

        "id": "102452128776"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17068725",

      "from": {

        "name": "Fahad Mn",

        "id": "100002866151044"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T10:05:53+0000",

      "updated_time": "2012-02-29T10:05:53+0000",

      "title": "Fahad Mn likes your profile change.",

      "link": "http://www.facebook.com/permalink.php?story_fbid=1901455672653&id=1729552298",

      "application": {

        "name": "Likes",

        "canvas_name": "awesomeprops",

        "namespace": "awesomeprops",

        "id": "2409997254"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17040077",

      "from": {

        "name": "Samantha Taverni",

        "id": "1526794709"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T09:06:52+0000",

      "updated_time": "2012-02-29T09:06:52+0000",

      "title": "Samantha Taverni, Wania Arigoni Ferraz and 3 others sent you requests in Gardens of Time.",

      "link": "http://apps.facebook.com/gardensoftime/?request_ids=356859504346130\u00252C197720540330055\u00252C279227825481869\u00252C253734161379003\u00252C343288815709880\u00252C340631205973229\u00252C356115391089215\u00252C303407576388882&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Gardens of Time",

        "canvas_name": "gardensoftime",

        "namespace": "gardensoftime",

        "id": "175251882520655"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17068071",

      "from": {

        "name": "Pascal Mailhebiau",

        "id": "559744057"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T08:59:20+0000",

      "updated_time": "2012-02-29T08:59:20+0000",

      "title": "Pascal Mailhebiau sent you a request in Dungeon Overlord.",

      "link": "http://apps.facebook.com/dungeonoverlord/?request_ids=166879393430212&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Dungeon Overlord",

        "canvas_name": "dungeonoverlord",

        "namespace": "dungeonoverlord",

        "id": "110362692359888"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17021567",

      "from": {

        "name": "ÇhøÇöläty Stuti",

        "id": "100000508258652"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T08:50:05+0000",

      "updated_time": "2012-02-29T08:50:05+0000",

      "title": "ÇhøÇöläty Stuti, Andrew Zhen and 59 others sent you requests in Hidden Chronicles.",

      "link": "http://apps.facebook.com/hidden-chronicles/?request_ids=375203565825977\u00252C354817294550646\u00252C198932803540863\u00252C246922215396573\u00252C308578282539461\u00252C311702518891562\u00252C240155796078406\u00252C334958419887975\u00252C332827710101104\u00252C189007427875266\u00252C329834353720129\u00252C184980528278434\u00252C193596120746665\u00252C199304090171019\u00252C113086898815366\u00252C293047017427755\u00252C359882170698718\u00252C119600538167247\u00252C359879204033911\u00252C392330560792556\u00252C331797233524475\u00252C178705998911104\u00252C138787209577744\u00252C242004775890319\u00252C313480195376282\u00252C382454165100178\u00252C299112793488097\u00252C252725151479050\u00252C122216694571289\u00252C262019560540890\u00252C185575904886607\u00252C332129716823851\u00252C118155634976319\u00252C376409065703776\u00252C331600806876323\u00252C122013024591689\u00252C249277758492646\u00252C320541984661860\u00252C357219747643397\u00252C303725859683252\u00252C305968766125465\u00252C284344974969326\u00252C292020364196916\u00252C331090826941329\u00252C342688539108078\u00252C297365700329785\u00252C336472193056181\u00252C281413348598520\u00252C122191017907504\u00252C329388550440509&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Hidden Chronicles",

        "canvas_name": "hidden-chronicles",

        "namespace": "hidden-chronicles",

        "id": "100333333405439"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17067941",

      "from": {

        "name": "Suresh Kumar",

        "id": "100000987389231"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T08:48:28+0000",

      "updated_time": "2012-02-29T08:48:28+0000",

      "title": "Suresh Kumar likes your post.",

      "link": "http://www.facebook.com/permalink.php?story_fbid=1901363870358&id=1729552298",

      "application": {

        "name": "Likes",

        "canvas_name": "awesomeprops",

        "namespace": "awesomeprops",

        "id": "2409997254"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17064786",

      "from": {

        "name": "Zahra Watinson",

        "id": "100003112009581"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T08:40:11+0000",

      "updated_time": "2012-02-29T08:40:11+0000",

      "title": "Zahra Watinson, Ýahýa ÂhmÂd and 3 others posted in Tanki Online (Official).",

      "link": "http://www.facebook.com/groups/128992757117932/400063790010826/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17041458",

      "from": {

        "name": "George Joseph",

        "id": "1002200268"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T08:39:05+0000",

      "updated_time": "2012-02-29T08:39:05+0000",

      "title": "George Joseph, Riyaz Kaduvakuzhy and Sunil Vallikunnu posted in മഴവില്ല്... RAINBOW...வானவில்.",

      "link": "http://www.facebook.com/groups/mazhavillukal/307931465938043/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17067655",

      "from": {

        "name": "Heike Jeschik",

        "id": "100002127501660"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T08:20:43+0000",

      "updated_time": "2012-02-29T08:20:43+0000",

      "title": "Heike Jeschik sent you a request in Texas Hold'em Poker (Deutsch).",

      "link": "http://apps.facebook.com/detexas/?request_ids=385178314845385&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Texas Hold'em Poker (Deutsch)",

        "canvas_name": "detexas",

        "namespace": "detexas",

        "id": "126683120737232"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17067650",

      "from": {

        "name": "Alexandre Santos",

        "id": "100003349826419"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T08:20:19+0000",

      "updated_time": "2012-02-29T08:20:19+0000",

      "title": "Alexandre Santos posted in DDTank.",

      "link": "http://www.facebook.com/groups/DDTank/334769559909068/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17067479",

      "from": {

        "name": "Dejan Evanicevic",

        "id": "100002625537548"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T08:00:20+0000",

      "updated_time": "2012-02-29T08:00:20+0000",

      "title": "Dejan Evanicevic sent you a request in Dragon Born Beta Sign-up.",

      "link": "http://apps.facebook.com/dragonborngame/?request_ids=219644974800217&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Dragon Born Beta Sign-up",

        "canvas_name": "dragonborngame",

        "namespace": "dragonborngame",

        "id": "307252889327742"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17064240",

      "from": {

        "name": "Torozx Na'x Juogja",

        "id": "100002500720027"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T07:52:57+0000",

      "updated_time": "2012-02-29T07:52:57+0000",

      "title": "Torozx Na'x Juogja and Andika Setiawan posted in Dd TaNk.",

      "link": "http://www.facebook.com/groups/LiFe4dDtAnK/310719635655011/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17021672",

      "from": {

        "name": "Osama Attal",

        "id": "100000685132532"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T07:39:38+0000",

      "updated_time": "2012-02-29T07:39:38+0000",

      "title": "Osama Attal and Ammar Omar Qaddoora posted in Facebook Friends Group.",

      "link": "http://www.facebook.com/groups/291031084277837/317831121597833/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17045638",

      "from": {

        "name": "Jess Ica",

        "id": "100000065801739"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T07:30:41+0000",

      "updated_time": "2012-02-29T07:30:41+0000",

      "title": "Jess Ica and Beatrix Trixi Grote posted in Flamme empor gegen Kindesmissbrauch.",

      "link": "http://www.facebook.com/groups/313697792011642/318233628224725/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17050582",

      "from": {

        "name": "Zulkarnain Cf",

        "id": "100000569641715"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T07:00:09+0000",

      "updated_time": "2012-02-29T07:00:09+0000",

      "title": "Zulkarnain Cf, Yener Tok and 2 others sent you requests in Texas HoldEm Poker.",

      "link": "http://apps.facebook.com/texas_holdem/?request_ids=353614964660651\u00252C190057767769637\u00252C328024673910268\u00252C357879247580420\u00252C305605852832686&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Texas HoldEm Poker",

        "canvas_name": "texas_holdem",

        "namespace": "texas_holdem",

        "id": "2389801228"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17066745",

      "from": {

        "name": "Holger Knübben",

        "id": "100001466790751"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T06:49:37+0000",

      "updated_time": "2012-02-29T06:49:37+0000",

      "title": "Holger Knübben sent you a request in Battle Stations.",

      "link": "http://apps.facebook.com/battlestations/?request_ids=333505956686718&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Battle Stations",

        "canvas_name": "battlestations",

        "namespace": "battlestations",

        "id": "18063885304"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17021681",

      "from": {

        "name": "ഇടതുപക്ഷം
സിപിഎം"
,

        "id": "100003091957197"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T05:40:31+0000",

      "updated_time": "2012-02-29T05:40:31+0000",

      "title": "ഇടതുപക്ഷം
സിപിഎം, Comrade Shamik Bhattacharya and 8 others posted in DYFI."
,

      "link": "http://www.facebook.com/groups/152724548155258/239059816188397/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17019390",

      "from": {

        "name": "Gerimis Wira",

        "id": "100003369098969"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T05:37:09+0000",

      "updated_time": "2012-02-29T05:37:09+0000",

      "title": "Gerimis Wira, 王威勝 and 47 others sent you requests in CityVille.",

      "link": "http://apps.facebook.com/cityville/?request_ids=218429731589221\u00252C138374906285625\u00252C162995960485690\u00252C174676142647738\u00252C392386620787811\u00252C173833106066232\u00252C342842259092656\u00252C252053874879590\u00252C138808679575133\u00252C281904301882941\u00252C193981757373037\u00252C351141628259360\u00252C268517509892510\u00252C336883123020236\u00252C259357360810512\u00252C225291727567122\u00252C119256814869554\u00252C316478048408635\u00252C397989916893081\u00252C338565246186875\u00252C388729237820352\u00252C241521105938060\u00252C316861141705361\u00252C250527658362513\u00252C140576496064183\u00252C310972038956888\u00252C123634844430308\u00252C323047257742894\u00252C279621825443235\u00252C226928634069236\u00252C238897139537565\u00252C279611512111272\u00252C316526538404190\u00252C380467115316090\u00252C289696327764901\u00252C337121906329852\u00252C357793250920590\u00252C377718885572332\u00252C182014951909103\u00252C381774625183399\u00252C370886916262308\u00252C140911669364996\u00252C353819204650905\u00252C287302204673579\u00252C176068949171707\u00252C263742890369568\u00252C284302241637836\u00252C181083082001730\u00252C198810970221153\u00252C227245990704938&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "CityVille",

        "canvas_name": "cityville",

        "namespace": "cityville",

        "id": "291549705119"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17064772",

      "from": {

        "name": "Aruns Nair",

        "id": "100001900560572"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T04:40:59+0000",

      "updated_time": "2012-02-29T04:40:59+0000",

      "title": "Aruns Nair added a photo of you.",

      "link": "http://www.facebook.com/photo.php?fbid=282006501872700&set=at.282005958539421.63870.100001900560572.1729552298&type=1",

      "application": {

        "name": "Today Calendar",

        "canvas_name": "todaycal",

        "namespace": "todaycal",

        "id": "51209591753"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17028428",

      "from": {

        "name": "Balakrishnapillai Babunair",

        "id": "100003589965652"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-29T04:13:23+0000",

      "updated_time": "2012-02-29T04:13:23+0000",

      "title": "Balakrishnapillai Babunair and Kuldeep Singh Deep posted in Joking group.",

      "link": "http://www.facebook.com/groups/187961031278538/264361273638513/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17059008",

      "from": {

        "name": "Ace Tashov",

        "id": "100001006444751"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T23:04:59+0000",

      "updated_time": "2012-02-28T23:04:59+0000",

      "title": "Ace Tashov subscribed to your public updates.",

      "link": "http://www.facebook.com/ace.tashov",

      "application": {

        "name": "Subscriptions",

        "id": "178960162176427"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17058411",

      "from": {

        "name": "Marc Oliver",

        "id": "100001798310410"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T22:35:00+0000",

      "updated_time": "2012-02-28T22:35:00+0000",

      "title": "Marc Oliver sent you a request in Herzen.",

      "link": "http://apps.facebook.com/herzenapp/?request_ids=329134333804719&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Herzen",

        "canvas_name": "herzenapp",

        "namespace": "herzenapp",

        "id": "218200214933182"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17057981",

      "from": {

        "name": "Paul Mok",

        "id": "100000515033319"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T22:15:55+0000",

      "updated_time": "2012-02-28T22:15:55+0000",

      "title": "Paul Mok sent you a request in Café World.",

      "link": "http://apps.facebook.com/cafeworld/?request_ids=261744617234915&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Café World",

        "canvas_name": "cafeworld",

        "namespace": "cafeworld",

        "id": "101539264719"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17047819",

      "from": {

        "name": "John Flerin",

        "id": "100002929270252"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T22:13:50+0000",

      "updated_time": "2012-02-28T22:13:50+0000",

      "title": "John Flerin, Nmaks Shajahan Abdulkhadar and Daniel Nugent sent you requests in MyCalendar - Birthdays.",

      "link": "http://apps.facebook.com/m_calendar/?request_ids=119050931556095\u00252C139559952833224\u00252C400568826625686&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "MyCalendar - Birthdays",

        "canvas_name": "m_calendar",

        "namespace": "m_calendar",

        "id": "33699672217"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17056782",

      "from": {

        "name": "Zehra Gul",

        "id": "1598073435"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T21:28:04+0000",

      "updated_time": "2012-02-28T21:28:04+0000",

      "title": "Zehra Gul sent you a request in Indiana Jones Adventure World.",

      "link": "http://apps.facebook.com/playadventureworld/?request_ids=318207858226562\u00252C238955959531910\u00252C339794776061678&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Indiana Jones Adventure World",

        "canvas_name": "playadventureworld",

        "namespace": "playadventureworld",

        "id": "130479640376964"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17039233",

      "from": {

        "name": "Abdul Rasheed Alanallur",

        "id": "100001111365723"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T20:35:30+0000",

      "updated_time": "2012-02-28T20:35:30+0000",

      "title": "Abdul Rasheed Alanallur and Shamba Bhanja sent you requests in My Smiles.",

      "link": "http://apps.facebook.com/mysmilesapp/?request_ids=250640861691528\u00252C377463358948252&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "My Smiles",

        "canvas_name": "mysmilesapp",

        "namespace": "mysmilesapp",

        "id": "157646491011878"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17043804",

      "from": {

        "name": "Shelane Harding",

        "id": "1094906716"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T20:31:41+0000",

      "updated_time": "2012-02-28T20:31:41+0000",

      "title": "Shelane Harding and Tim Weis sent you requests in Blackwood & Bell Mysteries.",

      "link": "http://apps.facebook.com/blackwoodandbell/?request_ids=357182724312599\u00252C287070738028192&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Blackwood & Bell Mysteries",

        "canvas_name": "blackwoodandbell",

        "namespace": "blackwoodandbell",

        "id": "239313489465198"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17038283",

      "from": {

        "name": "ASarah Jeux",

        "id": "100000237971964"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T19:43:07+0000",

      "updated_time": "2012-02-28T19:43:07+0000",

      "title": "ASarah Jeux sent you a request in Pioneer Trail.",

      "link": "http://apps.facebook.com/pioneertrail/?request_ids=119079864885953\u00252C376825582347267&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Pioneer Trail",

        "canvas_name": "pioneertrail",

        "namespace": "pioneertrail",

        "id": "266989143414"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17022443",

      "from": {

        "name": "Aria Manousaki",

        "id": "100000038476988"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T18:18:35+0000",

      "updated_time": "2012-02-28T18:18:35+0000",

      "title": "Aria Manousaki sent you a request in Pet Society.",

      "link": "http://apps.facebook.com/petsociety/?request_ids=228898960538805&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Pet Society",

        "canvas_name": "petsociety",

        "namespace": "petsociety",

        "id": "11609831134"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17053246",

      "from": {

        "name": "Samir Barman",

        "id": "100002146655975"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T18:11:10+0000",

      "updated_time": "2012-02-28T18:11:10+0000",

      "title": "Samir Barman invited you to the event padojatra.",

      "link": "http://www.facebook.com/events/162830017168972/",

      "application": {

        "name": "Events",

        "id": "2344061033"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17043989",

      "from": {

        "name": "Arup Chatterjee",

        "id": "100001920813240"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T17:55:54+0000",

      "updated_time": "2012-02-28T17:55:54+0000",

      "title": "Arup Chatterjee, Somesh Ghosh and Comrade Chowdhury posted in REDS.",

      "link": "http://www.facebook.com/groups/redselute/326771510707621/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17052802",

      "from": {

        "name": "Bucko Williams",

        "id": "1365364295"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T17:48:20+0000",

      "updated_time": "2012-02-28T17:48:20+0000",

      "title": "Bucko Williams sent you a request in Battle Pirates.",

      "link": "http://apps.facebook.com/battlepirates/?request_ids=381552285206149\u00252C123825357743234&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Battle Pirates",

        "canvas_name": "battlepirates",

        "namespace": "battlepirates",

        "id": "148669555176974"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17006338",

      "from": {

        "name": "Murali Narayanan",

        "id": "100002617681090"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T16:02:55+0000",

      "updated_time": "2012-02-28T16:02:55+0000",

      "title": "Murali Narayanan and Iv Junais posted in BEST..FRIENDS....",

      "link": "http://www.facebook.com/groups/132954416824935/151199681667075/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17040843",

      "from": {

        "name": "Murali Narayanan",

        "id": "100002617681090"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T16:01:11+0000",

      "updated_time": "2012-02-28T16:01:11+0000",

      "title": "Murali Narayanan posted in WORLD INFORMATION CENTER.",

      "link": "http://www.facebook.com/groups/188707194516899/308363382551279/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17050583",

      "from": {

        "name": "Anto M Guirado",

        "id": "567270534"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T15:40:54+0000",

      "updated_time": "2012-02-28T15:40:54+0000",

      "title": "Anto M Guirado sent you a request in Paradise Life.",

      "link": "http://apps.facebook.com/paradiselife/?request_ids=242211472532682&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Paradise Life",

        "canvas_name": "paradiselife",

        "namespace": "paradiselife",

        "id": "143547399002598"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17050368",

      "from": {

        "name": "Harees Sainulabdeen S",

        "id": "100001499035979"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T15:26:47+0000",

      "updated_time": "2012-02-28T15:26:47+0000",

      "title": "Harees Sainulabdeen S sent you a request in Best Friends.",

      "link": "http://apps.facebook.com/my_bestfriends/?request_ids=314774718579009&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Best Friends",

        "canvas_name": "my_bestfriends",

        "namespace": "my_bestfriends",

        "id": "55693831864"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17005331",

      "from": {

        "name": "Joy Fermin",

        "id": "1336364419"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T15:15:55+0000",

      "updated_time": "2012-02-28T15:15:55+0000",

      "title": "Joy Fermin, Anto M Guirado and 10 others sent you requests in FarmVille.",

      "link": "http://apps.facebook.com/onthefarm/?request_ids=152753904845656\u00252C323826164330011\u00252C175960189186410\u00252C130591413722744\u00252C184727434963843\u00252C354875777876555\u00252C119214711539277\u00252C319274064786697\u00252C394718800544740\u00252C332990876737270&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "FarmVille",

        "canvas_name": "onthefarm",

        "namespace": "onthefarm",

        "id": "102452128776"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17004846",

      "from": {

        "name": "Ben Tai",

        "id": "100002600902367"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T15:03:25+0000",

      "updated_time": "2012-02-28T15:03:25+0000",

      "title": "Ben Tai, Nur Ezzati Suhaimi and 10 others sent you requests in The Sims Social.",

      "link": "http://apps.facebook.com/thesimssocial/?request_ids=301536543242626\u00252C217308588366377\u00252C378399378836950\u00252C381151268571472\u00252C161096690676105\u00252C180421968739463\u00252C356494031048760\u00252C368680216490159\u00252C337231119646164\u00252C402499356433823\u00252C314955065220638\u00252C249938911761064\u00252C182240361888698\u00252C342224479151995\u00252C175513645897472&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "The Sims Social",

        "canvas_name": "thesimssocial",

        "namespace": "thesimssocial",

        "id": "144959615576466"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17047725",

      "from": {

        "name": "Adersh Sp",

        "id": "100002254677373"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T13:01:14+0000",

      "updated_time": "2012-02-28T13:01:14+0000",

      "title": "Adersh Sp posted in SILENT WISH.",

      "link": "http://www.facebook.com/groups/122670917837229/194180087352978/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17041212",

      "from": {

        "name": "Adersh Sp",

        "id": "100002254677373"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T12:59:32+0000",

      "updated_time": "2012-02-28T12:59:32+0000",

      "title": "Adersh Sp and Somprakash Dhar posted in [News] SCANNER [News]- A Political Group.",

      "link": "http://www.facebook.com/groups/newsscanner/330990076936454/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17003938",

      "from": {

        "name": "Max Ilmer",

        "id": "100002766740267"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T12:56:18+0000",

      "updated_time": "2012-02-28T12:56:18+0000",

      "title": "Max Ilmer, AronJan Benedict and 8 others posted in Tanki Online (Official).",

      "link": "http://www.facebook.com/groups/128992757117932/399416113408927/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17047328",

      "from": {

        "name": "Alan Chan",

        "id": "100000996658222"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T12:32:23+0000",

      "updated_time": "2012-02-28T12:32:23+0000",

      "title": "Alan Chan sent you a request in DoubleDown Casino - Free Slots, Blackjack & Poker.",

      "link": "http://apps.facebook.com/doubledowncasino/?request_ids=267028790038946&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "DoubleDown Casino - Free Slots, Blackjack & Poker",

        "canvas_name": "doubledowncasino",

        "namespace": "doubledowncasino",

        "id": "119468838217"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17046877",

      "from": {

        "name": "Daniel Odling",

        "id": "669594483"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T12:02:09+0000",

      "updated_time": "2012-02-28T12:02:09+0000",

      "title": "Daniel Odling sent you a request in Adventure Slots.",

      "link": "http://apps.facebook.com/adventureslots/?request_ids=252849141464308&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Adventure Slots",

        "canvas_name": "adventureslots",

        "namespace": "adventureslots",

        "id": "166753083345608"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17046864",

      "from": {

        "name": "Drakensang Online",

        "category": "Games/toys",

        "id": "115880358476014"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T12:01:28+0000",

      "updated_time": "2012-02-28T12:01:28+0000",

      "title": "Drakensang Online has new activity: 7 likes, 1 post and 131 views.",

      "link": "http://www.facebook.com/pages/Drakensang-Online/115880358476014",

      "application": {

        "name": "Pages",

        "id": "2530096808"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17046332",

      "from": {

        "name": "Bucko Williams",

        "id": "1365364295"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T11:25:47+0000",

      "updated_time": "2012-02-28T11:25:47+0000",

      "title": "Bucko Williams sent you a request in Caesars Casino.",

      "link": "http://apps.facebook.com/caesars/?request_ids=118588511603020&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Caesars Casino",

        "canvas_name": "caesars",

        "namespace": "caesars",

        "id": "275591942465870"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17045924",

      "from": {

        "name": "Nicolas Erickson",

        "id": "100001922726648"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T10:52:07+0000",

      "updated_time": "2012-02-28T10:52:07+0000",

      "title": "Nicolas Erickson sent you a request in Castle Age.",

      "link": "http://apps.facebook.com/castle_age/?request_ids=334032389982077&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Castle Age",

        "canvas_name": "castle_age",

        "namespace": "castle_age",

        "id": "46755028429"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17041663",

      "from": {

        "name": "Vishnu Prasad Prakash",

        "id": "752923178"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T10:25:13+0000",

      "updated_time": "2012-02-28T10:25:13+0000",

      "title": "Vishnu Prasad Prakash and Murali Narayanan posted in കമ്മ്യൂണിസ്റ്റ്‌
യുഗം."
,

      "link": "http://www.facebook.com/groups/126231487456581/259082944171434/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17045124",

      "from": {

        "name": "Lars Puls",

        "id": "100001286254238"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T09:44:59+0000",

      "updated_time": "2012-02-28T09:44:59+0000",

      "title": "Lars Puls sent you a request in Wild West Town.",

      "link": "http://apps.facebook.com/wildwesttown/?request_ids=350738828299936&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Wild West Town",

        "canvas_name": "wildwesttown",

        "namespace": "wildwesttown",

        "id": "102518706469143"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17007441",

      "from": {

        "name": "Janie Jones",

        "id": "100002193017084"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T09:27:53+0000",

      "updated_time": "2012-02-28T09:27:53+0000",

      "title": "Janie Jones sent you a request in Ravenwood Fair.",

      "link": "http://apps.facebook.com/ravenwoodfair/?request_ids=198671980233617&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Ravenwood Fair",

        "canvas_name": "ravenwoodfair",

        "namespace": "ravenwoodfair",

        "id": "120563477996213"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16998120",

      "from": {

        "name": "Comrade Chowdhury",

        "id": "100002224206220"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T07:37:04+0000",

      "updated_time": "2012-02-28T07:37:04+0000",

      "title": "Comrade Chowdhury, Kabi Ghosh and 5 others posted in REDS.",

      "link": "http://www.facebook.com/groups/redselute/326543810730391/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17040225",

      "from": {

        "name": "Santiago Jay-Vee",

        "id": "100001406175261"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T06:43:21+0000",

      "updated_time": "2012-02-28T06:43:21+0000",

      "title": "Santiago Jay-Vee and Matt Randolph Labador sent you requests in FBCredits Giveaway.",

      "link": "http://apps.facebook.com/myfbcredits/?request_ids=333868523331588\u00252C224604927636526&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "FBCredits Giveaway",

        "canvas_name": "myfbcredits",

        "namespace": "myfbcredits",

        "id": "355592194457083"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17042936",

      "from": {

        "name": "Spa Life",

        "category": "Games/toys",

        "id": "156455681111819"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T06:09:54+0000",

      "updated_time": "2012-02-28T06:09:54+0000",

      "title": "Spa Life has new activity: 65 likes, 1 post, 1 comment and 145 views.",

      "link": "http://www.facebook.com/pages/Spa-Life/156455681111819",

      "application": {

        "name": "Pages",

        "id": "2530096808"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17040872",

      "from": {

        "name": "Daisy Crawford",

        "id": "50315717"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T04:03:52+0000",

      "updated_time": "2012-02-28T04:03:52+0000",

      "title": "Daisy Crawford sent you a request in BINGO Blitz.",

      "link": "http://apps.facebook.com/bingoblitz/?request_ids=283466178390075&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "BINGO Blitz",

        "canvas_name": "bingoblitz",

        "namespace": "bingoblitz",

        "id": "108854979142742"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17040807",

      "from": {

        "name": "Catherine Langschied",

        "id": "100000695179133"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T03:59:46+0000",

      "updated_time": "2012-02-28T03:59:46+0000",

      "title": "Catherine Langschied sent you a request in Let's Make A Deal.",

      "link": "http://apps.facebook.com/lets-make-a-deal/?request_ids=246499858772178&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Let's Make A Deal",

        "canvas_name": "lets-make-a-deal",

        "namespace": "lets-make-a-deal",

        "id": "209843922367855"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17017067",

      "from": {

        "name": "Maria Lovegood",

        "id": "100003187343116"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T03:35:30+0000",

      "updated_time": "2012-02-28T03:35:30+0000",

      "title": "Maria Lovegood sent you a request in Coco Girl.",

      "link": "http://apps.facebook.com/cocogirl/?request_ids=397463620269584&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Coco Girl",

        "canvas_name": "cocogirl",

        "namespace": "cocogirl",

        "id": "175115139210950"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17040325",

      "from": {

        "name": "John Vu",

        "id": "748474769"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T03:31:08+0000",

      "updated_time": "2012-02-28T03:31:08+0000",

      "title": "John Vu sent you a request in Army Attack.",

      "link": "http://apps.facebook.com/armyattack/?request_ids=198089383625927&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "Army Attack",

        "canvas_name": "armyattack",

        "namespace": "armyattack",

        "id": "174582889219848"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17040126",

      "from": {

        "name": "陈凯雯",

        "id": "100002801844887"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T03:23:54+0000",

      "updated_time": "2012-02-28T03:23:54+0000",

      "title": "陈凯雯 sent you a request in 魔力烘焙坊.",

      "link": "http://apps.facebook.com/themagiccake/?request_ids=360116867343101&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "魔力烘焙坊",

        "canvas_name": "themagiccake",

        "namespace": "themagiccake",

        "id": "149776858458769"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17038582",

      "from": {

        "name": "Renjith Mathew",

        "id": "100001159122866"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-28T02:07:17+0000",

      "updated_time": "2012-02-28T02:07:17+0000",

      "title": "Renjith Mathew sent you a request in *Smiles.",

      "link": "http://apps.facebook.com/coolsmiles/?request_ids=332785486758900&ref=notif&app_request_type=user_to_user",

      "application": {

        "name": "*Smiles",

        "canvas_name": "coolsmiles",

        "namespace": "coolsmiles",

        "id": "33157600316"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16999147",

      "from": {

        "name": "Amit Bhattacharya",

        "id": "100001966047653"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T18:42:27+0000",

      "updated_time": "2012-02-27T18:42:27+0000",

      "title": "Amit Bhattacharya, Jyotirmoy Ghosh and Sayantan Banerjee posted in KHOBOR NIE KHOBORDARI (ORIGINAL).",

      "link": "http://www.facebook.com/groups/knkoriginal/198093860292466/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16983761",

      "from": {

        "name": "Anil Kuriyathi",

        "id": "100002009185869"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T17:08:37+0000",

      "updated_time": "2012-02-27T17:08:37+0000",

      "title": "Anil Kuriyathi, Che Pallam Uduma and 7 others posted in Dr.Thomas Isac.",

      "link": "http://www.facebook.com/groups/thomasisac/330444480340148/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17020865",

      "from": {

        "name": "Joseph Reid",

        "id": "100001939813790"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T16:15:46+0000",

      "updated_time": "2012-02-27T16:15:46+0000",

      "title": "Joseph Reid and Binny Dasappan like your link.",

      "link": "http://www.facebook.com/baozilove/posts/178055042309539",

      "application": {

        "name": "Likes",

        "canvas_name": "awesomeprops",

        "namespace": "awesomeprops",

        "id": "2409997254"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17027930",

      "from": {

        "name": "Joseph Reid",

        "id": "100001939813790"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T16:15:33+0000",

      "updated_time": "2012-02-27T16:15:33+0000",

      "title": "Joseph Reid likes your link.",

      "link": "http://www.facebook.com/baozilove/posts/184205131681830",

      "application": {

        "name": "Likes",

        "canvas_name": "awesomeprops",

        "namespace": "awesomeprops",

        "id": "2409997254"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17019415",

      "from": {

        "name": "Joseph Reid",

        "id": "100001939813790"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T16:13:53+0000",

      "updated_time": "2012-02-27T16:13:53+0000",

      "title": "Joseph Reid, Suresh Kumar, and 3 other friends like your link.",

      "link": "http://www.facebook.com/baozilove/posts/193373427435418",

      "application": {

        "name": "Likes",

        "canvas_name": "awesomeprops",

        "namespace": "awesomeprops",

        "id": "2409997254"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16999217",

      "from": {

        "name": "Sören Kalmarczyk",

        "id": "100001142899903"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T13:31:31+0000",

      "updated_time": "2012-02-27T13:31:31+0000",

      "title": "Sören Kalmarczyk, Dirk Hax and 3 others posted in Flamme empor gegen Kindesmissbrauch.",

      "link": "http://www.facebook.com/groups/313697792011642/317169164997838/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16982101",

      "from": {

        "name": "Profpa Varghese",

        "id": "100001568294208"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T12:59:38+0000",

      "updated_time": "2012-02-27T12:59:38+0000",

      "title": "Profpa Varghese, Abhilash Warrier and Amritha Nair posted in TRIVANDRUM GUIDE.",

      "link": "http://www.facebook.com/groups/239303582779073/337375196305244/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17024733",

      "from": {

        "name": "Vijesh Pc",

        "id": "100003276767069"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T12:59:34+0000",

      "updated_time": "2012-02-27T12:59:34+0000",

      "title": "Vijesh Pc likes your photo.",

      "link": "http://www.facebook.com/photo.php?fbid=1085080503784&set=a.1177630337472.22906.1729552298&type=1",

      "application": {

        "name": "Likes",

        "canvas_name": "awesomeprops",

        "namespace": "awesomeprops",

        "id": "2409997254"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16997051",

      "from": {

        "name": "Ko Yamu",

        "id": "100001638460831"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T11:37:19+0000",

      "updated_time": "2012-02-27T11:37:19+0000",

      "title": "Ko Yamu, Shamim Zx T StaliniZt and Ekalawya Onlineguru posted in INTERNATIONAL POLITICS.",

      "link": "http://www.facebook.com/groups/296946577034816/303833623012778/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17022220",

      "from": {

        "name": "Dirk Hax",

        "id": "100001510644521"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T10:07:52+0000",

      "updated_time": "2012-02-27T10:07:52+0000",

      "title": "Dirk Hax posted in Kindernotrufdienst.",

      "link": "http://www.facebook.com/groups/287250717992183/334433653273889/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16982806",

      "from": {

        "name": "Jayakumar Kb",

        "id": "1701507702"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T08:15:21+0000",

      "updated_time": "2012-02-27T08:15:21+0000",

      "title": "Jayakumar Kb posted in Padiyam Village.",

      "link": "http://www.facebook.com/groups/padiyamvillage/368078219877292/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16978022",

      "from": {

        "name": "K S Lalu Lalu",

        "id": "548764091"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T08:13:23+0000",

      "updated_time": "2012-02-27T08:13:23+0000",

      "title": "K S Lalu Lalu, Hakkim KP, and 2 other people subscribed to your public updates.",

      "link": "http://www.facebook.com/baozilove?sk=subscribers&notif_ids\u00255B0\u00255D=548764091&notif_ids\u00255B1\u00255D=100002930831880&notif_ids\u00255B2\u00255D=100002823502140&notif_ids\u00255B3\u00255D=100000749937940",

      "application": {

        "name": "Subscriptions",

        "id": "178960162176427"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17018879",

      "from": {

        "name": "Saji Nanathu",

        "id": "100002632264567"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T05:10:29+0000",

      "updated_time": "2012-02-27T05:10:29+0000",

      "title": "Saji Nanathu added you to the group Chithrageetham (ചിത്രഗീതം ) A Music Group.",

      "link": "http://www.facebook.com/groups/chithrageethamsajinanathu/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17015050",

      "from": {

        "name": "Mike Beck",

        "id": "100000253477589"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-27T01:31:09+0000",

      "updated_time": "2012-02-27T01:31:09+0000",

      "title": "Mike Beck likes your post in lara croft.",

      "link": "http://www.facebook.com/groups/40272054029/10150596227659030/",

      "application": {

        "name": "Likes",

        "canvas_name": "awesomeprops",

        "namespace": "awesomeprops",

        "id": "2409997254"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17011010",

      "from": {

        "name": "Lalsalam Comrades",

        "id": "100000210577671"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T21:38:52+0000",

      "updated_time": "2012-02-26T21:38:52+0000",

      "title": "Lalsalam Comrades accepted your friend request. Write on Lalsalam's Wall.",

      "link": "http://www.facebook.com/profile.php?id=100000210577671",

      "application": {

        "name": "Friends",

        "id": "2356318349"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16981153",

      "from": {

        "name": "Kuldeep Singh Deep",

        "id": "100000256498049"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T18:25:41+0000",

      "updated_time": "2012-02-26T18:25:41+0000",

      "title": "Kuldeep Singh Deep, Balakrishnapillai Babunair and Soman Karivellur posted in Joking group.",

      "link": "http://www.facebook.com/groups/187961031278538/262833687124605/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17007154",

      "from": {

        "name": "Alice Chang",

        "id": "1082704358"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T17:55:27+0000",

      "updated_time": "2012-02-26T17:55:27+0000",

      "title": "Alice Chang added you to the group Memory Island 猫格格.",

      "link": "http://www.facebook.com/groups/memoryisland2u/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16973744",

      "from": {

        "name": "Iv Junais",

        "id": "100001805160070"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T17:11:14+0000",

      "updated_time": "2012-02-26T17:11:14+0000",

      "title": "Iv Junais, ഇടതുപക്ഷം
സിപിഎം and Lakshmanan Vayal posted in DYFI."
,

      "link": "http://www.facebook.com/groups/girishaj/258682787546050/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17003564",

      "from": {

        "name": "Haris Ckd",

        "id": "100002528532442"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T14:44:09+0000",

      "updated_time": "2012-02-26T14:44:09+0000",

      "title": "Haris Ckd posted in MAMMOOTTY -THE KING OF INDIAN CINEMA.",

      "link": "http://www.facebook.com/groups/244452968974591/249005888519299/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16960187",

      "from": {

        "name": "Doğukan Kıvrak",

        "id": "100000356717233"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T14:13:16+0000",

      "updated_time": "2012-02-26T14:13:16+0000",

      "title": "Doğukan Kıvrak, Aqhu C Heze and 5 others posted in Tanki Online (Official).",

      "link": "http://www.facebook.com/groups/128992757117932/398022546881617/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16983033",

      "from": {

        "name": "K.m. Sheejan Kadirur",

        "id": "100002614453859"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T13:54:15+0000",

      "updated_time": "2012-02-26T13:54:15+0000",

      "title": "K.m. Sheejan Kadirur, Kabeer Katlat and 2 others posted in കമ്മ്യൂണിസ്റ്റ്‌
യുഗം."
,

      "link": "http://www.facebook.com/groups/126231487456581/257878134291915/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16978334",

      "from": {

        "name": "Helios D AL Ma'shumovic",

        "id": "100002294894347"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T13:50:56+0000",

      "updated_time": "2012-02-26T13:50:56+0000",

      "title": "Helios D AL Ma'shumovic sent you a request in Ninja Warz.",

      "link": "http://www.facebook.com/games?scrollto=confirm_147198662055&app_request_type=user_to_user",

      "application": {

        "name": "Ninja Warz",

        "canvas_name": "ninja-warz",

        "namespace": "ninja-warz",

        "id": "147198662055"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17002507",

      "from": {

        "name": "Akzz Shay",

        "id": "100002733475712"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T13:41:20+0000",

      "updated_time": "2012-02-26T13:41:20+0000",

      "title": "Akzz Shay added you to the group lalettan fanzzzzzzz.",

      "link": "http://www.facebook.com/groups/179241708852604/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17000480",

      "from": {

        "name": "Muhammed Rafi",

        "id": "100000470549038"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T11:16:39+0000",

      "updated_time": "2012-02-26T11:16:39+0000",

      "title": "Muhammed Rafi accepted your friend request. Write on Muhammed's Wall.",

      "link": "http://www.facebook.com/rafip6",

      "application": {

        "name": "Friends",

        "id": "2356318349"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_17000282",

      "from": {

        "name": "Ayman Slah",

        "id": "100001989881619"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T10:58:35+0000",

      "updated_time": "2012-02-26T10:58:35+0000",

      "title": "Ayman Slah accepted your friend request. Since he's new to Facebook, you should suggest people he knows.",

      "link": "http://www.facebook.com/ayman.slah2",

      "application": {

        "name": "Friends",

        "id": "2356318349"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16957458",

      "from": {

        "name": "Fysel Antheenadan",

        "id": "1844616957"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T09:42:18+0000",

      "updated_time": "2012-02-26T09:42:18+0000",

      "title": "Fysel Antheenadan, Vishnu Prasad Prakash and 8 others posted in REPORTER.",

      "link": "http://www.facebook.com/groups/144116732374994/150464431740224/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16999001",

      "from": {

        "name": "Denver Inguito Detalo",

        "id": "100000857677352"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T09:11:19+0000",

      "updated_time": "2012-02-26T09:11:19+0000",

      "title": "Denver Inguito Detalo posted in Dd TaNk.",

      "link": "http://www.facebook.com/groups/LiFe4dDtAnK/308807725846202/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16998141",

      "from": {

        "name": "Financil View",

        "id": "1293911121"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T07:45:11+0000",

      "updated_time": "2012-02-26T07:45:11+0000",

      "title": "Financil View added you to the group HEALTH AND YOU.",

      "link": "http://www.facebook.com/groups/187930697938776/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16953954",

      "from": {

        "name": "Comrade Red",

        "id": "100002650492162"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-26T04:27:54+0000",

      "updated_time": "2012-02-26T04:27:54+0000",

      "title": "Comrade Red, Samit Kumar Majumder and 2 others posted in REDS.",

      "link": "http://www.facebook.com/groups/redselute/325273677524071/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16985751",

      "from": {

        "name": "Kerem Yasar",

        "id": "1359755096"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T19:09:07+0000",

      "updated_time": "2012-02-25T19:09:07+0000",

      "title": "Kerem Yasar invited you to the event GÜÇ BİRLİĞİ KONSERİ.",

      "link": "http://www.facebook.com/events/249045511849222/",

      "application": {

        "name": "Events",

        "id": "2344061033"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16940679",

      "from": {

        "name": "Haris Ckd",

        "id": "100002528532442"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T16:56:03+0000",

      "updated_time": "2012-02-25T16:56:03+0000",

      "title": "Haris Ckd and Mervin Flores posted in MAMMOOTTY -THE KING OF INDIAN CINEMA.",

      "link": "http://www.facebook.com/groups/244452968974591/248467121906509/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16949264",

      "from": {

        "name": "George Joseph",

        "id": "1002200268"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T16:37:55+0000",

      "updated_time": "2012-02-25T16:37:55+0000",

      "title": "George Joseph, Sunil Vallikunnu and 3 others posted in മഴവില്ല്... RAINBOW...வானவில்.",

      "link": "http://www.facebook.com/groups/mazhavillukal/305595622838294/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16961466",

      "from": {

        "name": "Saleem Shakoor",

        "id": "100000617350681"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T16:34:16+0000",

      "updated_time": "2012-02-25T16:34:16+0000",

      "title": "Saleem Shakoor, Hyderali Puchippa and Suhail Madavoor posted in BEST..FRIENDS....",

      "link": "http://www.facebook.com/groups/132954416824935/149257908527919/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16978095",

      "from": {

        "name": "Saif Saifudeen",

        "id": "100001565728760"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T15:18:45+0000",

      "updated_time": "2012-02-25T15:18:45+0000",

      "title": "Saif Saifudeen and Sameer Kv posted in CHIRI ചിരി
ചിരി
പൊട്ടിച്ചിരി."
,

      "link": "http://www.facebook.com/groups/268004006563007/378716928825047/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16942545",

      "from": {

        "name": "Jens Höckelmann",

        "id": "100003037942629"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T15:13:01+0000",

      "updated_time": "2012-02-25T15:13:01+0000",

      "title": "Jens Höckelmann, Mimi DeathCore and 4 others posted in Flamme empor gegen Kindesmissbrauch.",

      "link": "http://www.facebook.com/groups/313697792011642/316115368436551/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16979826",

      "from": {

        "name": "Fahad CJ",

        "id": "100002812750698"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T13:05:31+0000",

      "updated_time": "2012-02-25T13:05:31+0000",

      "title": "Fahad CJ posted in D@/!/ce P@rTy.",

      "link": "http://www.facebook.com/groups/287123961360699/292936530779442/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16979797",

      "from": {

        "name": "حسام حسن",

        "id": "1217033438"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T13:03:16+0000",

      "updated_time": "2012-02-25T13:03:16+0000",

      "title": "حسام حسن sent you a request in المزرعة السعيدة.",

      "link": "http://www.facebook.com/games?scrollto=confirm_176919669032547&app_request_type=user_to_user",

      "application": {

        "name": "المزرعة السعيدة",

        "canvas_name": "playhappyfarm",

        "namespace": "playhappyfarm",

        "id": "176919669032547"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16951348",

      "from": {

        "name": "Roshan Ochoyi",

        "id": "100002959973414"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T09:23:23+0000",

      "updated_time": "2012-02-25T09:23:23+0000",

      "title": "Roshan Ochoyi and 緯華龍 posted in INTERNATIONAL POLITICS.",

      "link": "http://www.facebook.com/groups/296946577034816/302570623139078/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16933550",

      "from": {

        "name": "Profpa Varghese",

        "id": "100001568294208"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T09:05:18+0000",

      "updated_time": "2012-02-25T09:05:18+0000",

      "title": "Profpa Varghese posted in TRIVANDRUM GUIDE.",

      "link": "http://www.facebook.com/groups/239303582779073/336133773096053/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16976210",

      "from": {

        "name": "ചെഗുവേര
പ്രിയപ്പെട്ട
ചെഗുവേര"
,

        "id": "100002897051867"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T07:24:19+0000",

      "updated_time": "2012-02-25T07:24:19+0000",

      "title": "ചെഗുവേര
പ്രിയപ്പെട്ട
ചെഗുവേര posted in നമ്മുടെ
നാട്."
,

      "link": "http://www.facebook.com/groups/nammudenaadu/328251340554337/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16934531",

      "from": {

        "name": "Kuldeep Singh Deep",

        "id": "100000256498049"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T05:06:23+0000",

      "updated_time": "2012-02-25T05:06:23+0000",

      "title": "Kuldeep Singh Deep, Balakrishnapillai Babunair and Soman Karivellur posted in Joking group.",

      "link": "http://www.facebook.com/groups/187961031278538/261962220545085/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16932638",

      "from": {

        "name": "Mannathoor Wilson",

        "id": "1185173721"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T04:00:31+0000",

      "updated_time": "2012-02-25T04:00:31+0000",

      "title": "Mannathoor Wilson, Lakshmanan Vayal and 5 others posted in DYFI.",

      "link": "http://www.facebook.com/groups/152724548155258/236510426443336/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16938647",

      "from": {

        "name": "Samit Kumar Majumder",

        "id": "100001662067092"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T02:00:45+0000",

      "updated_time": "2012-02-25T02:00:45+0000",

      "title": "Samit Kumar Majumder and Jyotirmoy Ghosh posted in KHOBOR NIE KHOBORDARI (ORIGINAL).",

      "link": "http://www.facebook.com/groups/knkoriginal/196793273755858/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16970275",

      "from": {

        "name": "Murali Narayanan",

        "id": "100002617681090"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-25T00:31:35+0000",

      "updated_time": "2012-02-25T00:31:35+0000",

      "title": "Murali Narayanan posted in WORLD INFORMATION CENTER.",

      "link": "http://www.facebook.com/groups/188707194516899/306230336097917/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16926523",

      "from": {

        "name": "Yassine Sims",

        "id": "100003117953563"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-24T23:42:43+0000",

      "updated_time": "2012-02-24T23:42:43+0000",

      "title": "Yassine Sims, A Liane Addfor Sims and Christian Ray G. Oligo posted in The sims social.",

      "link": "http://www.facebook.com/groups/simsfamly/262472177162305/",

      "application": {

        "name": "Groups",

        "id": "2361831622"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16962831",

      "from": {

        "name": "Sunny Michael",

        "id": "100002835481023"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-24T16:59:28+0000",

      "updated_time": "2012-02-24T16:59:28+0000",

      "title": "Sunny Michael commented on Sajith Sharooq's photo of you.",

      "message": "I am proud of you dr bijju",

      "link": "http://www.facebook.com/photo.php?fbid=337681736253280&set=a.104629702891819.9044.100000343685082&type=1",

      "application": {

        "name": "Photos",

        "id": "2305272732"

      },

      "unread": 1

    },

    {

      "id": "notif_1729552298_16959489",

      "from": {

        "name": "حسام حسن",

        "id": "1217033438"

      },

      "to": {

        "name": "Bao Zi",

        "id": "1729552298"

      },

      "created_time": "2012-02-24T13:40:35+0000",

      "updated_time": "2012-02-24T13:40:35+0000",

      "title": "حسام حسن sent you a request in لعبة الواحة السعيدة .",

      "link": "http://www.facebook.com/games?scrollto=confirm_121253591264082&app_request_type=user_to_user",

      "application": {

        "name": "لعبة الواحة السعيدة ",

        "canvas_name": "happyoasis",

        "namespace": "happyoasis",

        "id": "121253591264082"

      },

      "unread": 1

    }

  ],

  "paging": {

    "previous": "https://graph.facebook.com/1729552298/notifications?format=json&limit=5000&since=1330519210&__paging_token=notif_1729552298_17031359&__previous=1",

    "next": "https://graph.facebook.com/1729552298/notifications?format=json&limit=5000&until=1330090835&__paging_token=notif_1729552298_16959489"

  },

  "summary": {

    "unseen_count": 99,

    "updated_time": "2012-02-29T12:40:10+0000"

  }

}

 
 

源文档 <https://developers.facebook.com/tools/explorer?method=GET&path=1729552298%2Fnotifications>

 
 

 
 

 
 

1.5 取用户信息

 
 

http://developers.facebook.com/docs/reference/rest/users.getInfo/

 
 

[
{
"uid": 100002627144445,
"pic": "http://profile.ak.fbcdn.net/hprofile-ak-snc4/195380_100002627144445_4930944_s.jpg"
}
]

 
 

源文档 <http://developers.facebook.com/docs/reference/rest/users.getInfo/>

 
 

http://www.facebook.com/dialog/friends?id=&app_id=123050457758183&redirect_uri=

 
 

或者使用 developers.facebook.com/tools/explorer?method=GET&path=me%2Fnotifications%2F%3Finclude_read%3D1

查询控制台

 
 

1.6 发送添加朋友请求

 
 

http://www.facebook.com/dialog/friends/?
id=brent&
app_id=123050457758183&
redirect_uri=http://www.example.com/response/

示例:http://www.facebook.com/dialog/friends?id=100001862563179&app_id=300106523381410&redirect_uri=http://pkrss.sinaapp.com

 
 

源文档 <http://developers.facebook.com/docs/reference/dialogs/friends/>

 
 

1.7 接受朋友游戏的请求

 
 

http://developers.facebook.com/docs/requests/

 
 

1.8 官方文档

We have deprecated this version of the JavaScript SDK. We recommend all developers switch to our new, improved JavaScript SDK.

If you upgrade to the new JavaScript SDK, please ensure you remove all references to the old JavaScript library, as they are incompatible and will cause your implementation to stop working. You can find references to the old JavaScript library by searching for the string "FeatureLoader.js.php".

 
 

FB.CanvasClient

FB.CanvasClient.add_windowSizeChanged

Subscribe to event 'windowSizeChanged'

FB.CanvasClient.getCanvasInfo

Get a dictionary of size information about the canvas.

FB.CanvasClient.get_timerInterval

The timer interval used by StartTimerToSizeToContent() to determine the size of the content in the iframe, and adjust the

FB.CanvasClient.remove_windowSizeChanged

Unsubscribe to event 'windowSizeChanged'

FB.CanvasClient.setCanvasHeight

Set the height for the iframe registered for this client instance.

FB.CanvasClient.set_timerInterval

The timer interval used by StartTimerToSizeToContent() to determine the size of the content in the iframe, and adjust the

FB.CanvasClient.startTimerToSizeToContent

Continually readjust the size of the iframe to match its contents.

FB.CanvasClient.stopTimerToSizeToContent

Use this to turn off continuous resizing.

 
 

FB.Connect

FB.Connect.addSignedPublicSessionDataToUrl

Get signed public session data and add it to the given url as query

FB.Connect.createApplication

Prompts the user to create their own application.

FB.Connect.forceSessionRefresh

Forces the current login session to refresh from login_status.

FB.Connect.getSignedPublicSessionData

Get a session proof structure that can be passed to another app as proof

FB.Connect.getUIServerDialogProperty

Returns a hard-coded property of a UI Server dialog.

FB.Connect.get_loggedInUser

Returns the uid of the currently logged in user.

FB.Connect.get_status

Get the current user's login status as a Waitable object.

FB.Connect.ifUserConnected

Use this function to take action depending on whether the user has

FB.Connect.inviteConnectUsers

Method for prompting the user to invite their friends to connect their

FB.Connect.isUIServerEnabled

Returns whether UI Server is enabled.

FB.Connect.logout

Log user out of current session as well as Facebook.

FB.Connect.logoutAndRedirect

Log user out from this session and Facebook, then redirect to the specified url.

FB.Connect.pollLoginStatus

This polls login status until you are connected, or timeout.

FB.Connect.requireSession

Call this function when you want to enforce that the

FB.Connect.showAddFriendDialog

Method for prompting the user with a dialog to add a friend.

FB.Connect.showAddSectionButton

Creates a button that can be clicked in order to prompt

FB.Connect.showBookmarkDialog

Provides an iFrame popup allowing the user to bookmark an

FB.Connect.showFeedDialog

This call lets a user publish a Feed story to his or her Wall

FB.Connect.showPermissionDialog

Method for prompting the user to grant the application one or more

FB.Connect.showProfileTabDialog

Displays a popup allowing the user to add the current application to

FB.Connect.showUIServerDialog

Provides an iframe popup for any UI Server method call.

FB.Connect.streamPublish

This method publishes a post to the user's stream using stream.publish

 
 

FB.ApiClient

FB.ApiClient.auth_getAppPublicKey

Client side call to auth.getAppPublicKey.

FB.ApiClient.auth_getSignedPublicSessionData

Client side call to auth.getSignedPublicSessionData.

FB.ApiClient.callMethod

Calls the specified Facebook API method with given parameters, or queues it on the Sequencer.

FB.ApiClient.connect_getUnconnectedFriendsCount

Returns the number of friends who have pending accounts on a Connect site.

FB.ApiClient.events_get

Client side call to events.get.

FB.ApiClient.events_getMembers

Client side call to events.getMembers.

FB.ApiClient.fbml_refreshImgSrc

Client side call to fbml.refreshImgSrc.

FB.ApiClient.fbml_refreshRefUrl

Client side call to fbml.refreshRefUrl.

FB.ApiClient.feed_getAppFriendStories

Return a list of all application stories recently published by the user's friends.

FB.ApiClient.feed_publishUserAction

This is not recommended - use FB.Connect.streamPublish instead.

FB.ApiClient.fql_query

Make a FQL query directly from the client.

FB.ApiClient.friends_get

Return a array of friend ids for the currently logged in user.

FB.ApiClient.get_apiKey

API key of your application

FB.ApiClient.get_session

Get session information for the currently logged in user.

FB.ApiClient.get_sessionWaitable

Retrieves the FB:Waitable for the session object.

FB.ApiClient.pages_getInfo

Client side call to pages.getInfo.

FB.ApiClient.pages_isAdmin

Client side call to pages.isAdmin.

FB.ApiClient.pages_isAppAdded

Client side call to pages.isAppAdded.

FB.ApiClient.pages_isFan

Client side call to pages.isFan.

FB.ApiClient.photos_addTag

Client side call to photos.addTag.

FB.ApiClient.photos_createAlbum

Client side call to photos.createAlbum.

FB.ApiClient.photos_get

Client side call to photos.get.

FB.ApiClient.photos_getAlbums

Client side call to photos.getAlbums.

FB.ApiClient.photos_getTags

Client side call to photos.getTags.

FB.ApiClient.preloadFQL_get

Uses callback on any preload fql data

FB.ApiClient.requireLogin

This method is deprecated - use FB.Connect.requireSession instead.

FB.ApiClient.revokeAuthorization

Revokes authorization for calling application to make API calls on behalf of given user

FB.ApiClient.sessionIsExpired

Determine if a particular session is expired yet.

FB.ApiClient.set_session

Sets the current session information.

FB.ApiClient.stream_get

Gets the stream on behalf of a user using a set of users.

FB.ApiClient.stream_getComments

Gets the full comments given a post_id from stream.get or the stream FQL table.

FB.ApiClient.stream_getFilters

Gets the filters (with relevant filter keys for stream.get) for the current user.

FB.ApiClient.users_getInfo

Client side call to users.getInfo.

FB.ApiClient.users_hasAppPermission

Client side call to users.hasAppPermission.

FB.ApiClient.users_isAppAdded

Client side call to users.isAppAdded.

FB.ApiClient.users_isAppUser

Determine if the user has authorized this application.

FB.ApiClient.users_setStatus

The preferred way to update the user's status is via FB.Connect.streamPublish.

 
 

FB.XFBML.Host

FB.XFBML.Host.get_areElementsReady

A Waitable object to indicate whether all XFBML elements are ready.

FB.XFBML.Host.parseDomElement

Start parse the DOM tree to search for

FB.XFBML.Host.parseDomTree

Start parse the DOM tree to search for

FB.XFBML.Host.refresh

Re-render all existing XFBML elements.

 
 

FB.XFBML.Conditions

FB.XFBML.Conditions.ifCanSee

Check if the current user can see

 
 

FB.Monitor

FB.Monitor.bind

Bind a function to a given context and arguments.

FB.Monitor.copy

Copies things from source into targed.

FB.Monitor.disableLogging

Turn off logging at the developer's request.

FB.Monitor.externalCallback

By default, all functions called within the Facebook library callstack

FB.Monitor.forEach

For looping through Arrays and Objects.

FB.Monitor.logFunction

Writes a given function call to the global page log,

FB.Monitor.logXFBML

Writes an XFBML element to the global page log.

FB.Monitor.loggingEnabled

Decide whether to send the logging messages on this page load.

FB.Monitor.provide

Provide a module or static class methods in the FB namespace.

FB.Monitor.redo

This is a simple but hacky solution to allow generic redoing of function

FB.Monitor.resolve

Resolve and optionally create intermediate properties.

FB.Monitor.scheduleSend

Schedule a call to send() with setTimeout if one is not already pending.

FB.Monitor.send

See if the sending object has loaded; if not, then just keep waiting.

FB.Monitor.subclass

Lazy loaded subclass definition.

FB.Monitor.wrapObject

Wraps a bunch of functions to record and log entry into the stack.

 
 

FB.Facebook

FB.Facebook.add_initCalled

Subscribe to event 'initCalled'.

FB.Facebook.get_baseDomain

Gets the base domain for your Connect site.

FB.Facebook.get_initialized

Get status of Facebook initialization as a Waitable object.

FB.Facebook.get_isInCanvas

Checks if the current page is inside the Facebook canvas or is an external

FB.Facebook.get_isInConnect

Checks if the current page is on your Facebook Connect site.

FB.Facebook.get_sessionState

DEPRECATED

FB.Facebook.get_sessionWaitable

Get API session as a Waitable object.

FB.Facebook.init

Initializes Facebook Connect for your implementation.

FB.Facebook.remove_initCalled

Unsubscribe from event 'initCalled'.

FB.Facebook.set_baseDomain

Sets the base domain for your Connect site.

 
 

FB.Waitable

FB.Waitable.add_changed

Subscribe to event 'changed'

FB.Waitable.onChange

If a function is registered to be executed upon

FB.Waitable.remove_changed

Unsubscribe to event 'changed'

FB.Waitable.resetChange

Remove all event subscribers that are waiting for Change event, including

FB.Waitable.waitForCondition

Watch for changes in ready state and result until condition is

FB.Waitable.waitForValue

Wait until result is ready and equal to expectedValue

FB.Waitable.waitUntilReady

If we don't need to wait, execute the callback, otherwise

 
 

FB.BatchSequencer

FB.BatchSequencer.execute

Start executing all pending operations in a single batched

 
 

FB.PendingResult

FB.PendingResult.setPendingResult

After a result has been obtained, sets the result and/or exception

 
 

源文档 <http://developers.facebook.com/docs/reference/oldjavascript/>

 
 

 
 

 
 

  1. Dialog

2.1 利用request.ui向朋友发送请求

 
 

向所有朋友发送请求示例:

http://www.facebook.com/dialog/apprequests?app_id=300106523381410&message=Facebook%20Dialogs%20are%20so%20easy!&redirect_uri=http://pkrss.sinaapp.com

 
 

2.2 发送共享消息

 
 

Feed Dialog

 
 

源文档 <http://developers.facebook.com/docs/reference/dialogs/feed/>

 
 

 
 

示例:

 
 

http://www.facebook.com/dialog/feed?app_id=300106523381410&link=http://developers.facebook.com/docs/reference/dialogs/&picture=http://fbrell.com/f8.jpg&name=Facebook%20Dialogs&caption=Reference%20Documentation&description=Using%20Dialogs%20to%20interact%20with%20users.&message=Facebook%20Dialogs%20are%20so%20easy!&redirect_uri=http://pkrss.sinaapp.com

 
 

2.3 添加好友

Requests Dialog

 
 

源文档 <http://developers.facebook.com/docs/reference/dialogs/requests/>

 
 

示例:

http://www.facebook.com/dialog/friends/?id=100002627144445&app_id=300106523381410&redirect_uri=http://pkrss.sinaapp.com

 
 

如果1000000262xx 已发出邀请,则出现:


 
 

理论上使用notification接收请求,然后如果点接受,则使用Requests Dialog来处理请求,使用表单处理确认及忽略请求。

 
 

一键礼物

2012年3月12日

19:51

 
 

64位系统 office 插件要装 office web plugin

 
 

implmemnt:

1.gift

component checkMySomeRequest()

 
 

 
 

100001862563169 liandeliang@yahoo.com.cn Lian deliang

100002627144445 416320079@qq.com Li Ku

100003091373140 h298905@163.com Azhe Huang

1729552298 bd@bbgsite.com Bao zi

 
 

 
 

 
 

App App_id

pkrss_web 300106523381410

 
 

 
 

 
 

 
 

1.search by:facebook application request notification

 
 

2.Facebook Shows Application Requests in the Notification Channel in Potentially Significant Test

http://www.insidefacebook.com/2010/12/09/tests-application-requests-notifications/

 
 

3.How To: Send An Application Request Using The Facebook Graph API

http://www.masteringapi.com/tutorials/how-to-send-an-application-request-using-the-facebook-graph-api/44/

 
 

 
 

4.Redirect a Fb app request notification to the app requests page

http://stackoverflow.com/questions/7781307/redirect-a-fb-app-request-notification-to-the-app-requests-page

 
 

当用户点某个应用邀请接受时,发送:

http://apps.facebook.com/[app_name]/?request_ids=[request_ids]

 
 

批量从好友中发送pkrssweb的消息,消息内容为:Facebook%20Dialogs%20are%20so%20easy!

http://www.facebook.com/100001862563169/apprequests?app_id=300106523381410&message=Facebook%20Dialogs%20are%20so%20easy!&redirect_uri=http://pkrss.sinaapp.com/server3/index.php?task=mmosite4firebox&scope=user_photos,publish_stream,status_update,friends_status&response_type=token

 
 

5.fb.ui/apprequests 在线测试工具 可以看 APP_ACCESS_TOKEN

http://www.fbrell.com/fb.ui/apprequests

 
 

可以查授权的:

http://developers.facebook.com/tools/explorer?method=GET&path=100001862563169

 
 

向用户发送一条应用程序的请求:

document.getElementById('send-app-to-user').onclick = function() {

FB.api(

'/me/apprequests',

{ message: 'From the app to the user.' },

'POST',

Log.info.bind('sent app-to-user request'));

}

 
 

查看当前的消息

pending requests

这上下两个结果怎么一模一样?

查询请求对象ID的相关信息: 参见:http://developers.facebook.com/docs/requests/

https://graph.facebook.com/<REQUEST_OBJECT_ID>?access_token=APP_ACCESS_TOKEN

 
 

查询当前应用的应用请求

https://graph.facebook.com/100001862563169/apprequests?access_token=AAAAAKvQdWksBABJIiBsNT122qIjrHXNv50OJcNT0KQYs0hyB0psCZBpLuzNuZBocfPqDWdmgJqiAF9Y5JLdhm8jZBWLxJlScgrLsyZCt2ICZBGgDsNLrz

 
 

可以随便查询当前用户的栏位及连接等信息,替换fields中的值,及access_token及可:参考 http://developers.facebook.com/docs/reference/api/user/

https://graph.facebook.com/me?fields=apprequests&access_token=AAAAAKvQdWksBABJIiBsNT122qIjrHXNv50OJcNT0KQYs0hyB0psCZBpLuzNuZBocfPqDWdmgJqiAF9Y5JLdhm8jZBWLxJlScgrLsyZCt2ICZBGgDsNLrz

 
 

fql:http://developers.facebook.com/docs/reference/fql/

 
 

Facebook Invites:http://userscripts.org/scripts/show/43682

 
 

请求权限:http://developers.facebook.com/tools/explorer?method=GET&path=me%2Fnotifications%2F

 
 

2012-3-10

好像我找的好友请求玩游戏是不需要的,只要应用程序的邀请?

 
 

7. 应用程序授权,使用scope(所有的权限都不支持apprequests)

ex: 参考 http://developers.facebook.com/docs/authentication/

https://www.facebook.com/dialog/oauth?client_id=YOUR_APP_ID&redirect_uri=YOUR_URL&scope=email,read_stream

ex:https://www.facebook.com/dialog/oauth?client_id=300106523381410&scope=user_about_me,user_activities,s&redirect_uri=http://pkrss.sinaapp.com

 
 

应用程序授权:

https://graph.facebook.com/oauth/access_token?client_id=300106523381410&redirect_uri=http://pkrss.sinaapp.com/server3/index.php?task=mmosite4firebox&client_secret=44a7b7d7d840753c112d55a030ef09f3&code=user_photos,publish_stream,status_update,friends_status,read_requests


 

8 使用fb.api需要fb.init + fb.login, 而fb.login需要较验当前的host.

 
 

9. 查询当前用户的所有请求: 参考:http://developers.facebook.com/docs/reference/fql/apprequest/

 
 

SELECT recipient_uid, sender_uid, request_id, app_id FROM apprequest WHERE recipient_uid = me() AND app_id = 182197005148613

fql:需要同时知道app id

 
 

ex:

https://graph.facebook.com/145619942227639?access_token=AAAAAKvQdWksBABJIiBsNT122qIjrHXNv50OJcNT0KQYs0hyB0psCZBpLuzNuZBocfPqDWdmgJqiAF9Y5JLdhm8jZBWLxJlScgrLsyZCt2ICZBGgDsNLrz

 
 

https://graph.facebook.com/me/apprequests?access_token=AAAEQ8f64jqIBAPmBYFMROyuhHEZAMCXVyh6m70DSPTajOvOujsQXF6rsjcbjHuu0fFHipRZADUdp3GNi2akzElI3juDhWZAfknAbweLSYCsWVxTU5ZAt

 
 

fql:

https://graph.facebook.com/100001862563169/fql?q=SELECT recipient_uid, request_id, sender_uid, app_id,message,data FROM apprequest WHERE recipient_uid = me() AND app_id in ()?access_token=AAAEQ8f64jqIBADufOlWB9SjDZApKQKZA96YJLezUIUxbJPzjIb3S8oz7YPemqhq6XAcO8YZA2b4pX8uKkEqMg0XAVsKaBWWH1q1P3hBszfjNtmqI4eJ

 
 

2012-3-11

只能通过fui处理了,不过必须将相关东西处理到pkrss上.

 
 

记录日志选项

2012年2月26日

14:10

 
 

Components/facebook.js 前面

const BASE_CHECK_INTERVAL = 5*60*1000; // 5 minutes

const DEBUG = false;

const VERBOSITY = 0; //

 
 

Default/preferece/facebook.js 前面

pref("extensions.facebook.debug", false);

 
 

好友请求

2012年2月22日

21:39

 
 

2012-3-4

1.facebook.js -> facebook.com (facebook.notifications.get)

2. .com -> .js = data

data.friend_requests 为好友请求 // row:802

3.然后创建请求

new SetNotif(data.friend_requests, 'facebook-reqs-updated', fbSvc

, function( self, delta ) {

dispatcher.notify( null, topic, newVal );

SetNotify构造函数会发送topic消息,参数newVal为新内容大小 // row:100

SetNotif.items = data.friend_requests // friend_requests=[100001862563169]

4.SetNotif.Update() => 呼叫 function(self,delta) // delta=上面的friend_request

5.回调函数

fbSvc.getUsersInfo(delta, function(users) {

会执行查询用户信息

 
 

 
 

以前:

 
 

查找you.req

在facebook.js里

 
 

fbSvc._reqs = new SetNotif(data.friend_requests, 'facebook-reqs-updated', fbSvc

, function( self, delta ) {

fbSvc.getUsersInfo(delta, function(users) {

debug( "Got friend reqs", users.length );

for each (var user in users) {

self.items[user.id] = user;

fbSvc.notify(user, 'facebook-new-req', user.id);

fbSvc.showPopup('you.req', user.pic_sq, user.name + ' wants to be your friend',

'http://www.facebook.com/reqs.php');

}

});

});

 
 

_showPopup: function(type, pic, label, url) {

debug('showPopup', type, pic, label, url);

try {

if (!this._alertService)

this._alertService = Cc["@mozilla.org/alerts-service;1"].getService(Ci.nsIAlertsService);

if (this._prefService.getBoolPref('extensions.facebook.notifications.growl')) {

var notifyTitle = this.stringBundle.GetStringFromName("notificationtitle");

if (url) {

this._alertService.showAlertNotification(pic, notifyTitle, label,

true, url, new AlertObserver() );

} else {

this._alertService.showAlertNotification(pic, notifyTitle, label);

}

return true;

}

} catch (e) {

debug('caught', e);

}

 
 

// either native FF alerts are not available or they aren't being used

this._numAlertsObj.value++;

var win = Cc["@mozilla.org/appshell/appShellService;1"]

.getService(Ci.nsIAppShellService).hiddenDOMWindow;

var left = win.screen.width - 215;

var top = win.screen.height - 105*this._numAlertsObj.value;

win.openDialog('chrome://facebook/content/notifier.xul', '_blank',

'chrome,titlebar=no,popup=yes,left=' + left + ',top=' + top + ',width=210,height=100',

pic, label, url, this._numAlertsObj);

return true;

}

 
 

技术细节:

this.callMethod('facebook.notifications.get', [], function(data) {

https://api.facebook.com/method/facebook.notifications.get

 
 

启动调试记录:

 
 

const BASE_CHECK_INTERVAL = 5*60*1000; // 5 minutes

const DEBUG = true;

const VERBOSITY = 2;

 
 

 
 

在fbToolbar.js里有个监听器: 监听好友消息等:

fbToolbarObserver

 
 

监听如下事件:

topics_of_interest: [ 'facebook-session-start'

, 'facebook-friends-updated'

, 'facebook-friend-updated'

, 'facebook-new-friend'

, 'facebook-session-end'

, 'facebook-msgs-updated'

, 'facebook-pokes-updated'

, 'facebook-event-invs-updated'

, 'facebook-group-invs-updated'

, 'facebook-reqs-updated'

, 'facebook-new-day'

// , 'facebook-status-set-result'

, 'facebook-status-updated'

],

 
 

如果事件为如下key,则对应更新value中的值:

topicToXulId: { 'facebook-msgs-updated': 'facebook-notification-msgs'

, 'facebook-pokes-updated': 'facebook-notification-poke'

, 'facebook-reqs-updated': 'mm-facebook-notification-reqs'

, 'facebook-event-invs-updated':'facebook-notification-event-invs'

, 'facebook-group-invs-updated':'facebook-notification-group-invs'

},

 
 

如果在components/facebook.js下查找 facebook-reqs-updated, 只会找到:

fbSvc._reqs = new SetNotif(data.friend_requests, 'facebook-reqs-updated', fbSvc

, function( self, delta ) {

fbSvc.getUsersInfo(delta, function(users) {

debug( "Got friend reqs", users.length );

for each (var user in users) {

         alert(user.name + ' wants to be your friend');

self.items[user.id] = user;

fbSvc.notify(user, 'facebook-new-req', user.id);

fbSvc.showPopup('you.req', user.pic_sq, user.name + ' wants to be your friend',

'http://www.facebook.com/reqs.php');

}

});

});

 
 

在firefox错误控制台中输出:

FacebookService: notification data:, {"messages":{"unread":0,"unseen":0,"most_recent":0},"pokes":{"unread":0,"most_recent":0},"shares":{"unread":0,"most_recent":0},"notification_counts":{"unseen":1},"friend_requests_counts":{"unread":1,"unseen":0},"friend_requests":[100001862563169],"group_invites":[],"event_invites":[]}

 
 

另一个输出

FacebookService: raw response from callMethod: '[{"uid":100001862563169,"name":"Deliang Lian","status":null,"pic_small":"http:\/\/profile.ak.fbcdn.net\/hprofile-ak-snc4\/186742_100001862563169_6300660_t.jpg","pic_square":"http:\/\/profile.ak.fbcdn.net\/hprofile-ak-snc4\/186742_100001862563169_6300660_q.jpg","wall_count":0,"notes_count":null,"profile_update_time":1304145629},{"uid":551654201,"name":"Bole Chen","status":null,"pic_small":"http:\/\/profile.ak.fbcdn.net\/hprofile-ak-snc4\/70851_551654201_7808811_t.jpg","pic_square":"http:\/\/profile.ak.fbcdn.net\/hprofile-ak-snc4\/70851_551654201_7808811_q.jpg","wall_count":13,"notes_count":null,"profile_update_time":1305792877},{"uid":720384950,"name":"Alger Chen","status":null,"pic_small":"http:\/\/profile.ak.fbcdn.net\/hprofile-ak-ash2\/48978_720384950_4014_t.jpg","pic_square":"http:\/\/profile.ak.fbcdn.net\/hprofile-ak-ash2\/48978_720384950_4014_q.jpg","wall_count":6,"notes_count":0,"profile_update_time":1330162039},{"uid":1158680261,"name":"Damo Cdamo","status":null,"pic_small":"http:\/\/profile.ak.fbcdn.net\/static-ak\/rsrc.php\/v1\/yi\/r\/odA9sNLrE86.jpg","pic_square":"http:\/\/profile.ak.fbcdn.net\/static-ak\/rsrc.php\/v1\/yo\/r\/UlIqmHJn-SK.gif","wall_count":0,"notes_count":null,"profile_update_time":1323251258},{"uid":1211884034,"name":"Benson Lee","status":null,"pic_small":"http:\/\/profile.ak.fbcdn.net\/static-ak\/rsrc.php\/v1\/yi\/r\/odA9sNLrE86.jpg","pic_square":"http:\/\/profile.ak.fbcdn.net\/static-ak\/rsrc.php\/v1\/yo\/r\/UlIqmHJn-SK.gif","wall_count":0,"notes_count":null,"profile_update_time":1306843822},{"uid":1775884571,"name":"Wei Zhao","status":null,"pic_small":"http:\/\/profile.ak.fbcdn.net\/hprofile-ak-snc4\/276076_1775884571_299290679_t.jpg","pic_square":"http:\/\/profile.ak.fbcdn.net\/hprofile-ak-snc4\/276076_1775884571_299290679_q.jpg","wall_count":null,"notes_count":null,"profile_update_time":null},{"uid":100001436774879,"name":"Youngman Winger","status":null,"pic_small":"http:\/\/profile.ak.fbcdn.net\/static-ak\/rsrc.php\/v1\/yi\/r\/odA9sNLrE86.jpg","pic_square":"http:\/\/profile.ak.fbcdn.net\/static-ak\/rsrc.php\/v1\/yo\/r\/UlIqmHJn-SK.gif","wall_count":0,"notes_count":null,"profile_update_time":1297305404},{"uid":100002902968194,"name":"\u4e2d\u91d1\u8f6f\u901a","status":null,"pic_small":"http:\/\/profile.ak.fbcdn.net\/hprofile-ak-snc4\/273638_100002902968194_8171477_t.jpg","pic_square":"http:\/\/profile.ak.fbcdn.net\/hprofile-ak-snc4\/273638_100002902968194_8171477_q.jpg","wall_count":1,"notes_count":null,"profile_update_time":1322206751},{"uid":100003091373140,"name":"Azhe Huang","status":null,"pic_small":"http:\/\/profile.ak.fbcdn.net\/static-ak\/rsrc.php\/v1\/yi\/r\/odA9sNLrE86.jpg","pic_square":"http:\/\/profile.ak.fbcdn.net\/static-ak\/rsrc.php\/v1\/yo\/r\/UlIqmHJn-SK.gif","wall_count":0,"notes_count":null,"profile_update_time":1330511731},{"uid":100003131813047,"name":"Leicc Lchenchun","status":null,"pic_small":"http:\/\/profile.ak.fbcdn.net\/hprofile-ak-ash2\/372643_100003131813047_1577581011_t.jpg","pic_square":"http:\/\/profile.ak.fbcdn.net\/hprofile-ak-ash2\/372643_100003131813047_1577581011_q.jpg","wall_count":1,"notes_count":null,"profile_update_time":1321580481}]'

 
 

Like this web

2012年2月22日

21:11

 
 

<html>

<head>

<title>My Great Web page</title>

</head>

<body>

<iframe src="http://www.facebook.com/plugins/like.php?href=http://pkrss.sinaapp.com"

scrolling="no" frameborder="0"

style="border:none; width:450px; height:80px"></iframe>

</body>

</html>

1 comment:

seoul korea airport said...

Some countries' institutions, when considering issuing
a loan to a client, will demand a safekeeping receipt.
whether an SEO services is an affordable SEO company, it is important to check
whether theirs is a professional SEO company or not,
because many companies may quote cheap to make their offer.
Being in the loop and having recently explored most of the top article directories, there's a list of article directories I'd like to tell you about.