Not sure if some stuff is inserted by javascript and not included in your copy pasta, but try this.
Change all instances of the.wifi.login.url to the url of the login page, then install the script below using TamperMonkey.
'G5' seems to be the checkbox
'G2' is the login button
The script will just load the page and then click those two items after 100ms.
// ==UserScript==
// @name Wheelee's Wifi Login
// @namespace forum.pinoypc.net
// @description Login to Wheelee's Wifi when it disconnects at 2am
// @include http://the.wifi.login.url/*
// @version 0.0.1
// @grant none
// ==/UserScript==
if (window.location.href.match('the.wifi.login.url'))
{
setTimeout(function ()
{
document.getElementById('G5').click();
document.getElementById('G2').click();
}, 100);
}
See TamperMonkey FAQ #102 on installing scripts.
You'll be doing this using the second to last option (copy paste) [preferred, click the video tutorial link]
or save into a file like xyz.user.js and install using the last option.
http://tampermonkey.net/faq.php#Q102