Skip to content

Instantly share code, notes, and snippets.

@git2samus
Created December 29, 2011 17:37
Show Gist options
  • Save git2samus/1535169 to your computer and use it in GitHub Desktop.
Save git2samus/1535169 to your computer and use it in GitHub Desktop.
Chromium user-script to automatically refresh Outlook Web Access mailbox
// ==UserScript==
// @match <target-url>
// ==/UserScript==
var interval = 60; // seconds
var links = document.links;
for (var i=0; i<links.length; i++) {
if (links[i].textContent && links[i].textContent.trim() == "Check Messages") {
var cm_link = links[i];
function refresh_f() {
cm_link.onclick();
};
window.setInterval(refresh_f, interval*1000);
break;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment