// <--
// ------------------------------ Frame rollover functions -------------------------------------- //
var siteText = [
					'<h1>Welcome to eMB Group</h1><p>Please run your mouse over a frame to learn more about our separate businesses, or click on a frame to visit our sites.</p>',
					'<h1>YourSiteMaker</h1><p>No hosting or complicated installation just sign up and off you go. Your site will be LIVE in minutes. Choose from a range of templates and designs.</p>', 
					'<h1>3G Web Design</h1><p>Internet and IT services company focusing on the creative design and development of web sites, E-commerce, print and new media.</p>', 
					'<h1>3G Graphic Design</h1><p>From print to web media, we have a wide range of experience and a team of extremely creative designers.</p>', 
					'<h1>Octavo</h1><p>Octavo is a feature rich roles based Content Management System that allows you to build and modify your site with no programming knowledge.</p>', 
					'<h1>IT Services</h1><p>4G Technology provide the opportunity to solve all your IT and Web needs in one place. With experts in Hardware, Software, Training, Web and Graphics Design</p>', 
					'<h1>PainlessCMS</h1><p>Earn extra money by selling websites to your customers; add your own branding and set your own pricing.</p>', 
					'<h1>Voip 4 Business</h1><p>A wide range of specialists are ready to attend to your voip and telecom needs; to reduce your costs and increase efficiency.</p>', 
				];   // rollover text

// Change the mouseover image
function textDisplay(site) {
	document.getElementById("frame").innerHTML = siteText[site];
}

// reset the mouseover image
function textReset() {
	document.getElementById("frame").innerHTML = siteText[0];
}

// ------------------------------ Roller Over Image Functions -------------------------------------- //
function initRollovers() {
	if (!document.getElementById) return
	
	var aPreLoad = new Array();
	var sTempSrc;
	var aImages = document.getElementsByTagName('img');

	for (var i = 0; i < aImages.length; i++) {		
		if (aImages[i].className == 'imgover') {
			var src = aImages[i].getAttribute('src');
			var ftype = src.substring(src.lastIndexOf('.'), src.length);
			var hsrc = src.replace(ftype, '-o'+ftype);

			aImages[i].setAttribute('hsrc', hsrc);
			
			aPreLoad[i] = new Image();
			aPreLoad[i].src = hsrc;
			
			aImages[i].onmouseover = function() {
				sTempSrc = this.getAttribute('src');
				this.setAttribute('src', this.getAttribute('hsrc'));
			}	
			
			aImages[i].onmouseout = function() {
				if (!sTempSrc) sTempSrc = this.getAttribute('src').replace('-o'+ftype, ftype);
				this.setAttribute('src', sTempSrc);
			}
		}
	}
}

window.onload = initRollovers;

// ------------------------------------ Image pop ups --------------------------------------- //
function popup(url,name,height,width) {
	var newWindow = window.open(url, name, "height="+height+",width="+width+",toolbar=no,menubar=no,scrollbars=yes,resizable=yes,status=no");
	newWindow.focus();
	return newWindow;
}

// -------------------------------- Show Progress of Upload ---------------------------------- //
function showProgress() {
	document.getElementById('uploadprogress').style.display = 'block';    
   	return true;
}

// --------------------------------------- Stop a Link --------------------------------------- //
function stopLink() {
	alert('You can only book one slot, to book another slot you must first delete your existing slot');
	
	return false;
}

// --------------------------------------- Print Page --------------------------------------- //
function printPage() {
	window.print();  
}

// --------------------------------------- Submit Form --------------------------------------- //
function submitForm()
{
  document.form.submit();
}
// -->