Mirror of Quill
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

24 lines
755 B

function reload_syndications() {
$.getJSON("/micropub/syndications", function(data){
if(data.targets) {
$("#syndication-container").html('<ul></ul>');
for(var i in data.targets) {
var target = data.targets[i].target;
var favicon = data.targets[i].favicon;
$("#syndication-container ul").append('<li><button data-syndication="'+target+'" class="btn btn-default btn-block"><img src="'+favicon+'" width="16" height="16"> '+target+'</button></li>');
}
bind_syndication_buttons();
} else {
}
console.log(data);
});
}
function bind_syndication_buttons() {
$("#syndication-container button").unbind("click").click(function(){
$(this).toggleClass('btn-info');
return false;
});
}