// JavaScript Document
var XMLHttpRequestObject = new Array();
//function for swap image menu
function changemenu(idmenu,image) {
	document.getElementById(idmenu).src = image;
}
//function clear field
function clearfield(idfield) {
	document.getElementById(idfield).value = "";
}
function topballon() {
	var totalheight = document.body.clientHeight;
	var remainheigt = totalheight - 370;
	var totalwidht = document.body.clientWidth;
	var remainwidth = ( totalwidht - 1024 ) / 2;
	remainwidth = remainwidth + 30;
	document.getElementById("topballon").style.top = remainheigt+"px";
	document.getElementById("topballon").style.left = remainwidth+"px";
	document.getElementById("topballon").style.display = "inline";
}
function bottomballon() {
	var totalheight = document.body.clientHeight;
	var remainheigt = totalheight - ( 370 - 206 );
	var totalwidht = document.body.clientWidth;
	var remainwidth = ( totalwidht - 1024 ) / 2;
	remainwidth = remainwidth + 30;
	var paddingleft = ( 248 - 162 );
	document.getElementById("bottomballon").style.top = remainheigt+"px";
	document.getElementById("bottomballon").style.paddingLeft = paddingleft+"px";
	document.getElementById("bottomballon").style.left = remainwidth+"px";
	document.getElementById("bottomballon").style.display = "inline";
}
function loadpage() {	
	topballon();
	bottomballon();
}
function movetopballon() {
	var totalwidht = document.body.clientWidth;
	var remainwidth = ( totalwidht - 1024 ) / 2;
	remainwidth = remainwidth + 30;
	if(remainwidth < 0) {
		remainwidth = 0;
	}
	document.getElementById("topballon").style.left = remainwidth+"px";
}
function movebottomballon() {
	var totalwidht = document.body.clientWidth;
	var remainwidth = ( totalwidht - 1024 ) / 2;
	remainwidth = remainwidth + 30;
	var paddingleft = ( 248 - 162 );
	if(remainwidth < 0) {
		remainwidth = 0;
	}
	document.getElementById("bottomballon").style.paddingLeft = paddingleft+"px";
	document.getElementById("bottomballon").style.left = remainwidth+"px";
}
function movepage() {	
	movetopballon();
	movebottomballon();
}
