From 3467e4ae17295f4b11ffd114c59c00802730ba54 Mon Sep 17 00:00:00 2001 From: Giuseppe Bilotta Date: Thu, 19 Aug 2010 12:56:21 +0200 Subject: [PATCH] Initial commit --- provvstudienna.user.js | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 provvstudienna.user.js diff --git a/provvstudienna.user.js b/provvstudienna.user.js new file mode 100644 index 0000000..ee45378 --- /dev/null +++ b/provvstudienna.user.js @@ -0,0 +1,30 @@ +// ==UserScript== +// @name Provveditorato Studi Enna Fix +// @description Fix the site from the Provveditorato agli Studi di Enna +// @namespace http://oblomov.myopenid.com +// @include http://provvstudienna.it/* +// @include http://*.provvstudienna.it/* +// @author Giuseppe "Oblomov" Bilotta +// @version 20100819 +// ==/UserScript== + +if (typeof(unsafeWindow) == 'undefined') unsafeWindow = window; + +(function () { + var marq = unsafeWindow.document.getElementById('externalmarquee'); + if (marq) { + var url = marq.getAttribute('src').replace(/\\/g,'/'); + xhr = new XMLHttpRequest(); + xhr.open("GET", url, true); + xhr.onreadystatechange = function() { + if (xhr.readyState == 4) { + if (xhr.status == 200) { + marq.innerHTML = xhr.responseText; + } else { + marq.innerHTML = 'impossibile caricare le news'; + } + } + } + xhr.send(); + } + })(); -- 2.32.0.93.g670b81a890