-
Notifications
You must be signed in to change notification settings - Fork 7
/
autoPost.js
32 lines (28 loc) · 1022 Bytes
/
autoPost.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
function previewPublish(id) {
lookupSession();
var ajax = new Ajax();
ajax.responseType = Ajax.FBML;
ajax.requireLogin = true;
ajax.ondone = function(transport) {
document.getElementById('prePub_'+id).setInnerFBML(transport);
document.getElementById('prePub_'+id).toggleClassName('hidden');
}
ajax.post(ajaxUrl+"?p=ajax&m=previewPublish&id="+id+"&userid="+userid+"&sessionKey="+sessionKey);
}
function showCaption(id) {
document.getElementById('caption_'+id).toggleClassName('hidden');
}
function hidePreviewPublish(id) {
document.getElementById('prePub_'+id).toggleClassName('hidden');
}
function postPublish(id) {
lookupSession();
var ajax = new Ajax();
ajax.responseType = Ajax.FBML;
ajax.requireLogin = true;
ajax.ondone = function(transport) {
document.getElementById('prePub_'+id).setInnerFBML(transport);
document.getElementById('prePub_'+id).toggleClassName('hidden');
}
ajax.post(ajaxUrl+"?p=ajax&m=postPublish&id="+id+"&userid="+userid+"&sessionKey="+sessionKey);
}