function changeState(element,key) { img=document.getElementById('img_'+element+'_'+key); item=EVAL('value_'+element+'['+key+']'); state=1; switch (state) { case '1' : img.src="/images/checkbox/7.gif"; break; default : img.src="/images/checkbox/7.gif"; } } var disableOnClick=false; function CheckBoxGroup (name,init,type) { var name; var checkboxs; var init; var current; var count=0; var sPrice = 0; var sPriceNL = 0; this.name=name; this.init=init; this.type=type; this.checkboxs=new Array(); this.count=0; element=document.getElementById(this.name); //get the associated hidden data field this.init=element.value; this.addBox = function(name) { if (this.init==name && this.type=='single' ) { cb=new CheckBox(name,1,this.type); } else if ( this.type=='single') { cb=new CheckBox(name,0,this.type); } else { cb=new CheckBox(name,this.init,this.type); } this.checkboxs[this.count]=cb; this.count++; img=document.getElementById('img_'+this.name+'_'+name); //get the associated images img.src=cb.displayState(this.type); } this.onClick= function (name,img) { if (this.type=='single') { if(fullpass){ return false; } if (disableOnClick && 1==0) { alert ('Changes to registration type are not allowed on confirmed bookings'); return false; } element=document.getElementById(this.name); //get the associated hidden data field for(i=0;i