<!-- added -->
function register_select_account() {
	$('register-company-name','register-company-size').invoke('hide');
	if($F("e_123")==707){ // Business
		$('register-company-name','register-company-size').invoke('show');	
	}
}
function eula ( ) {
	if($('eula').visible()) { $('eula').hide(); } else { $('eula').show(); }
}

var fpBanner = Class.create({
	initialize: function(){ this.nav=$('fp-nav-ul'); this.nxtExt='-1';
		Event.observe(this.nav,'click',this.doTab.bindAsEventListener(this));
		this.pObjArr=$('fpBanner').select('div.fp-panel'); this.pObjArr[0].setStyle({display:'block'});
		this.navAArr=this.nav.select('a'); this.navAArr[0].addClassName('Sel');
		var arr=window.location.toString().split("#"); this._doTab(arr[1],this.nav.select('a')[(arr[1]-1)]);
		setInterval(this.swPic.bind(this),4000);
	},
	swPic:function(){
		if($('fp1').visible()) {
			$('fp1').setStyle({backgroundImage:'url(/images/content/pic01'+this.nxtExt+'.png)'});
			this.nxtExt = this.nxtExt.empty() ? '-1' : '';
		}
	},
	doTab:function(e){ var o=Event.element(e);
		if(o.nodeName.toUpperCase()=="LI") { o=o.down('a'); } var arr=o.href.split("#"); this._doTab(arr[1],o);
	},
	_doTab:function(no,o){
		if ($('fp'+no)) {
			this.navAArr.invoke('removeClassName','Sel'); this.pObjArr.invoke('hide'); 
			$('fp'+no).setStyle({display:'block'}); o.addClassName('Sel');
		}
	}
});

function pfBannerInitialize ( ) {
	if($('fpBanner')) { var fpBannerObj = new fpBanner(); } else { pfBannerInitialize.defer(); }
}

function phoneShow(id, url,span) {
	if(span=="u") {$('user_p_h').hide();$('user_p_s').show();}
	if(span=="a1") {$('a1_p_h').hide();$('a1_p_s').show();}
	if(span=="a2") {$('a2_p_h').hide();$('a2_p_s').show();}
	
	var site_url = "http://"+url+"/phone_view.php?id="+id;
	var aj = new Ajax.Request(  
		site_url, {  
		method:'get',   
		parameters: id,   
		onComplete: getResponse  
		}  
	);  
}  
	
function getResponse(aj) {
	$('p_view').update(aj.responseText);
}
	
function showFeedback() {
	$('showFB').hide();
	$('hideFB').show();
	$('feedback').show();
}

function hideFeedback() {
	$('hideFB').hide();
	$('showFB').show();
	$('feedback').hide();
}

//--------------------------------------------
//disable enter key from form submit
function disableEnterKey(e){
	//alert(123);
     var key;     
     if(window.event)
          key = window.event.keyCode; //IE
     else
          key = e.which; //firefox     
     return (key != 13);
}


