function radioertek(radioObj)
	{
		if(!radioObj)
	    	return '';
	    var radioLength = radioObj.length;
	    if(radioLength == undefined)
	    	if(radioObj.checked)
	        	return radioObj.value;
	        else
	        	return '';
	    for(var i = 0; i < radioLength; i++)
        	{
            	if(radioObj[i].checked)
                	{
	                	return radioObj[i].value;
	                }
	        }
	    return '';
	}

function enter_()
	{
	    window.moveTo(0,0);
	    if (document.all)
		    {
		      top.window.resizeTo(screen.availWidth,screen.availHeight);
	    	}
	    else if (document.layers||document.getElementById)
		    {
		      if (top.window.outerHeight<screen.availHeight||top.window.outerWidth<screen.availWidth)
	    	  {
		        top.window.outerHeight = screen.availHeight;
		        top.window.outerWidth = screen.availWidth;
	      	  }
		    }
        document.getElementById('enter_id').style.height=(document.getElementById('footer').offsetTop+10)+'px';
        document.getElementById('enter_id').style.width =(document.body.clientWidth+5)+'px';
    }

function distance_load()
{
    var n=browser();

	if (n=="Opera")
	    {
	    }
	else if (n!="Microsoft Internet Explorer")
	    {
	    }
	else
	    {
            document.getElementById('distance_id').height=document.getElementById('footer').offsetTop-840;
	    }
}

function valid()
	{
		var form = document.basket_form;
        if(form.name.value=='')
        	{
                alert("Kérjük töltse ki a név mezőt!");
	           	form.name.focus();
    	       	form.name.select();
 	    		return false;
            }

        else if(form.city.value=='')
        	{
		    	alert("Kérjük adja meg a helységet!");
            	form.city.focus();
 	    		return false;
            }
        else if(form.zip.value=='')
             {
		     	alert("Kérjük adja meg az irányítószámot!");
        		form.zip.focus();
			 	return false;
             }
		else if(form.address.value=='')
        	{
            	alert("Kérjük adja meg a címet!");
            	form.address.focus();
 	    		return false;
            }
        else if(form.mobil.value=='')
        	{
            	alert("Kérjük adja meg mobilszámát!");
            	form.mobil.focus();
 	    		return false;
            }
        else if(form.email.value=='')
        	{
            	alert("Az e-mail mező kitöltése kötelező!");
            	form.email.focus();
	 	    	return false;
            }

        else if(form.mode.value=='')
        	{
            	alert("Válasszon szállítási módot!");
            	form.mode.focus();
	 	    	return false;
            }

        else if (!/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(form.email.value))
        	{
            	alert('Nem megfelelő az E-mail cím!')
	            form.email.focus();
	            return false;
            }
        else if (form.zip.value.length!=4  | isNaN(form.zip.value))
        	{
            	alert('Nem megfelelő irányítószám!')
	            form.zip.focus();
	            return false;
            }
        else
        	{
	    		return true;
		    }

	}

function poser(plusz,what,width___)
	{
		if (window.innerHeight)
	       {
	       		pos = window.pageYOffset;
	       }
	    else if (document.documentElement && document.documentElement.scrollTop)
	       {
	       		pos = document.documentElement.scrollTop;
	       }
	    else if (document.body)
	       {
	    		pos = document.body.scrollTop;
	       }

        pos=(pos+plusz);

	    document.getElementById(what).style.top = pos + 'px';

        u=(document.body.clientWidth-width___)/2;
        document.getElementById(what).style.left = u + 'px';

	}

function pc()
	{
document.getElementById('next_div').innerHTML='';		
document.picture.src='theme/tr.gif';
	    document.picture.style.border='none';
	    document.picture.style.width='1px';
        document.picture.style.height='1px';
        document.picture.style.visibility ='hidden';
        document.getElementById('alpha_id').style.visibility ='hidden';
        document.getElementById('alpha_id').style.width ='1px';
	    document.getElementById('alpha_id').style.height ='1px';
	}

function tc()
	{
    	document.getElementById('details_table_id').style.visibility ='hidden';
    	document.getElementById('details_table_id').style.width='1px';
		document.getElementById('details_table_id').style.height='1px';
    	document.getElementById('details_table_id').innerHTML='';
        document.getElementById('alpha_id').style.visibility ='hidden';
        document.getElementById('alpha_id').style.width ='1px';
        document.getElementById('alpha_id').style.height ='1px';
	}

function t_(text__)
	{
        document.getElementById('details_table_id').style.width='320px';
        document.getElementById('details_table_id').style.height='500px';
        document.getElementById('details_table_id').style.border='2px solid #FF8905';
        poser(10,'details_table_id',300);
        document.getElementById('details_table_id').innerHTML=text__;
        document.getElementById('details_table_id').style.visibility ='visible';
        document.getElementById('alpha_id').style.width =(document.body.clientWidth+5)+'px';
        document.getElementById('alpha_id').style.height=(document.getElementById('footer').offsetTop+10)+'px';
        document.getElementById('alpha_id').style.visibility ='visible';
    }

function p(pic__,width__,height__)
	{
		document.picture.src=pic__;
	    document.getElementById('picture_id').style.border='2px solid #FFCCCC';
        document.picture.style.height=height__+'px';
        document.picture.style.width=width__+'px';
        poser(10,'picture_table_id',width__);
        document.picture.style.visibility ='visible';
        document.getElementById('alpha_id').style.width =(document.body.clientWidth+5)+'px';
        document.getElementById('alpha_id').style.height=(document.getElementById('footer').offsetTop+10)+'px';
        document.getElementById('alpha_id').style.visibility ='visible';
    }

function pp(pic__,width__,height__)
	{
        document.picture.src='theme/tr.gif';
        document.picture.style.height=height__+'px';
        document.picture.style.width=width__+'px';
        poser(10,'picture_table_id',width__);
        document.picture.src=pic__;
    }

function pm(pic__,width__,height__,max_)
	{
        var pics=pic__.split(',');
        var picsw=width__.split(',');
        var picsh=height__.split(',');
        var numr=''
        for(i=0;i<max_;i++)
        	{
               numr+="&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span onclick=\"pp('"+pics[i]+"','"+picsw[i]+"','"+picsh[i]+"');\" style='cursor: pointer;'>"+(i+1)+"</span>";
            }
        document.getElementById('next_div').innerHTML='További képek: '+numr;
        p(pics[0],picsw[0],picsh[0])
    }

var button_up;
button_up = new Image();
button_up.src = "http://promaster.hu/pokershop/theme/button_up.png";
var button_;
button_ = new Image();
button_.src = "http://promaster.hu/pokershop/theme/button.png";
function cb(w,m)
	{
    	if(m==1)
        	{
            	document.getElementById(w).style.backgroundImage="url('"+button_up.src+"')";
            }
        else
        	{
            	document.getElementById(w).style.backgroundImage="url('"+button_.src+"')";
            }
    }


function FlashCode(width_,height_,where_,what_,transparent_,id_,loop_,bg_)
{
document.getElementById(where_).innerHTML='<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="'+width_+'" height="'+height_+'" id="'+id_+'" align="middle"> \n'+
											  '<param name="movie" value="'+what_+'" /><param name="quality" value="high" /><param name="wmode" value="'+transparent_+'" /><param name="bgcolor" value="#'+bg_+'" /><param name="loop" value="'+loop_+'" /><param name="menu" value="false" /> \n'+
                                              '<embed src="'+what_+'" quality="high" loop="'+loop_+'" wmode="'+transparent_+'" menu="false" bgcolor="#'+bg_+'" width="'+width_+'" height="'+height_+'" name="'+id_+'" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" /> \n'+
                                              '</object>';
}

function close_this()
	{
      document.getElementById('open_').innerHTML='';
    }