var oldwhat




//menucontents="<ul  class='horizontal_list'>"
function flicker(what){

document.getElementById("h"+oldwhat.id).style.display="none";
document.getElementById("h"+what.id).style.display="block";
oldwhat=what
}




function catchbackspace(evt) {//================================================
e=(evt)? evt:window.event
tx=document.getElementById('sfor');
kc=e.keyCode;

if (kc==13) {

slen=document.myForm0.sfor.value

//focus();
//sgoclick();
clicker();
return false;
}
if (kc==8 && (tx.value=='Your e-mail address'||tx.value=='A valid e-mail address please')) {

tx.value="";

return;
}
}

function clicker() {

slen=document.myForm0.sfor.value;

 if (slen.indexOf(' ')==-1 && 0<slen.indexOf('@') && slen.indexOf('@')+1 < slen.length) {

 sgoclick();
return false;
 }else{
 alert ('Invalid email address!');
 return false;
}
}

function sgoclick(){



hsh=document.location.hash;
hashbit="?"+slen;
if (hsh.length>0 && hash.indexOf("ttp:")>0){
hashbit="cpedia2/index.htm#"+hsh.substr(1)+hashbit
} else{
hashbit="cpedia_db.php"+hashbit;
}

//document.location.href=hashbit;
//setTimeout(function(){document.location.replace(hashbit); }, 0);
document.location.replace(hashbit);
return false;



}
        window.onload = function() {
            //tx=document.getElementById('sfor');
            //tx.value='Your e-mail address'
}
function showreg_pp(){
pppdo="y";
showreg_do();
}
function showreg_norm(){
pppdo="n";
showreg_do();
}
function showreg_do(){
document.getElementById("contactwrap").style.display="none";
document.getElementById("big_stuff").style.display="none";
document.getElementById("accountwrap").style.display="none";
document.getElementById("aboutwrap").style.display="none";

document.getElementById("t_reg").style.display="none";
document.getElementById("t_nuggets").style.display="inline-block";
document.getElementById("t_contact").style.display="inline-block";
document.getElementById("t_about").style.display="inline-block";
document.getElementById("t_contact").style.display="inline-block";
//document.getElementById("loginwrap").removeChild(document.getElementById("loginwrap").childNodes[2]);
idto="logreg"
element = document.getElementById(idto);
  element.parentNode.removeChild(element);
logreg=document.createElement("object");
logreg.id="logreg";
if(pppdo=="y"){
  logreg.data="http://www.ceannard.com/ceannardupdate.php?"+puid+"||||||"+foldr+"|pp";
}else{
  logreg.data="http://www.ceannard.com/ceannardupdate.php?"+puid+"|||||||norm";
  }
   if (navigator.appName == 'Microsoft Internet Explorer'){
   logreg.classid="clsid:25336920-03F9-11CF-8FD0-00AA00686F13";
   logreg.height="260px";
   logreg.width="600px";
   }else{
   logreg.type="text/html";
   logreg.style.height="260px";
   logreg.style.width="600px";
   }
document.getElementById("loginwrap").appendChild(logreg);
document.getElementById("loginwrap").style.display="block";

}
function showcont(){
document.getElementById("big_stuff").style.display="none";
document.getElementById("loginwrap").style.display="none";
document.getElementById("accountwrap").style.display="none";
document.getElementById("aboutwrap").style.display="none";
document.getElementById("contactwrap").style.display="block";
document.getElementById("t_contact").style.display="none";
document.getElementById("t_nuggets").style.display="inline-block";
document.getElementById("t_reg").style.display="inline-block";
document.getElementById("t_about").style.display="inline-block";

}
function showabout(){
document.getElementById("big_stuff").style.display="none";
document.getElementById("loginwrap").style.display="none";
document.getElementById("accountwrap").style.display="none";
document.getElementById("contactwrap").style.display="none";
document.getElementById("aboutwrap").style.display="block";
document.getElementById("t_about").style.display="none";
document.getElementById("t_nuggets").style.display="inline-block";
document.getElementById("t_reg").style.display="inline-block";
document.getElementById("t_contact").style.display="inline-block";
document.getElementById("t_contact").style.display="inline-block";
}
function showaccount(){
document.getElementById("big_stuff").style.display="none";
document.getElementById("loginwrap").style.display="none";
document.getElementById("contactwrap").style.display="none";
document.getElementById("aboutwrap").style.display="none";
document.getElementById("accountwrap").style.display="block";
document.getElementById("t_account").style.display="none";
document.getElementById("t_nuggets").style.display="inline-block";
document.getElementById("acc").data="ceannardaccount.php?"+logstat;
}
function shownuggets(){
document.getElementById("big_stuff").style.display="block";
document.getElementById("loginwrap").style.display="none";
document.getElementById("accountwrap").style.display="none";
document.getElementById("aboutwrap").style.display="none";
document.getElementById("contactwrap").style.display="none";
document.getElementById("t_reg").style.display="inline-block";
document.getElementById("t_account").style.display="inline-block";
document.getElementById("t_contact").style.display="inline-block";
document.getElementById("t_about").style.display="inline-block";
document.getElementById("t_contact").style.display="inline-block";
document.getElementById("t_nuggets").style.display="none";

}



function loadstuffstand(){


}
function cleardoc(){

}
function moreless(what){
alert(what.innerHTML);
}
function loadasset(flname){
// remove windows media player to do

document.getElementById('selector').style.display='none';
//document.getElementById('bpfu').style.display='none';
document.getElementById('theatre').style.display='block';
vh=document.getElementById("vid_load")
vidiv=document.getElementById("viddiv")
stopplayer();
vidiv.style.display='none'


get_assetXML(flname)
show_slides()
show_slide_tab.style.display='none';
nsld=1;
//show_transcript()
}
function closething(){

}
function close_stuff(what){
if (what=="login"){
document.getElementById("loginwrap").style.display="none";
}
if (what=="contact"){
document.getElementById("contactwrap").style.display="none";
}
if (what=="account"){
document.getElementById("accountwrap").style.display="none";
}
if (what=="about"){
document.getElementById("aboutwrap").style.display="none";
}
document.getElementById("big_stuff").style.display="block";
}
/*

if (Get_Cookie( 'ITLonview')){

(Get_Cookie( 'ITLonview'))}


}


// -------------------- end start --------------------
function setcookies(){

try{

Set_Cookie( 'ITLonview', 'it works', '', '/', '', '' )
Set_Cookie( 'ITLvpos', 'it works', '', '/', '', '' )

}catch (err){
alert(err.description)
}


}
*/

