// This JavaScript is executed as the head portion of the document loads
// It looks if the document was accessed through formlogin by checking if
// the literal 'formlogin' is part of the window.location
// If not, a new window.location is generated which routes through formlogin
// Ignores if preview is on local drive C:
//
if (location.href.indexOf('formlogin')<1 && location.href.indexOf('C:')<1){
pattern = /(http|https)(:\/\/www.bu.edu)(.*)/;
pattern.exec(window.location);
var newLoc = RegExp.$1+RegExp.$2+'/formlogin'+RegExp.$3;
window.location = newLoc;
}