Last active
August 29, 2015 14:02
-
-
Save patrickskim/2d58610af61b491a3251 to your computer and use it in GitHub Desktop.
Remove gifbin from Hipchat
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var post_url = "https://giddyapps.hipchat.com/history/room/428265/2014/06/18"; | |
$("a").each(function(){ | |
var str = "" + $(this).attr("href") + "" | |
if (str.match(/gifb/)) { | |
var $form = $(this).closest("table").find("form"); | |
$.post( | |
post_url, | |
{ | |
action: "delete", | |
message_id: $form.find("input[name=message_id]").val(), | |
xsrf_token: $form.find("input[name=xsrf_token]").val(), | |
message_index: $form.find("input[name=message_index]").val() | |
} ); | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment