


function setFlash(){

var flashMovie=parent.getFlashMovieObject("topi");
//flashMovie.Rewind();
flashMovie.GotoFrame(2);
flashMovie.Rewind();


}



/***********************************************
* DHTML Billboard script- © Dynamic Drive (www.dynamicdrive.com)
* This notice must stay intact for use
* Visit http://www.dynamicdrive.com/ for full source code
***********************************************/

//List of transitional effects to be randomly applied to billboard:
var billboardeffects=["Slide(slideStyle='push')"]

//var billboardeffects=["Iris"] //Uncomment this line and input one of the effects above (ie: "Iris") for single effect.

var tickspeed=6000 //ticker speed in miliseconds (2000=2 seconds)
var effectduration=500 //Transitional effect duration in miliseconds
var hidecontent_from_legacy=1 //Should content be hidden in legacy browsers- IE4/NS4 (0=no, 1=yes).

var filterid=Math.floor(Math.random()*billboardeffects.length)

document.write('<style type="text/css">\n')
if (document.getElementById)
document.write('.billcontent{display:none;\n'+'filter:progid:DXImageTransform.Microsoft.'+billboardeffects[filterid]+'}\n')
else if (hidecontent_from_legacy)
document.write('#contentwrapper{display:none;}')
document.write('</style>\n')

var selectedDiv=0
var totalDivs=0

function contractboard(){
var inc=0
while (document.getElementById("billboard"+inc)){
document.getElementById("billboard"+inc).style.display="none"
inc++
}
}

function expandboard(){
var selectedDivObj=document.getElementById("billboard"+selectedDiv)
contractboard()
if (selectedDivObj.filters){
if (billboardeffects.length>1){
filterid=Math.floor(Math.random()*billboardeffects.length)
selectedDivObj.style.filter="progid:DXImageTransform.Microsoft."+billboardeffects[filterid]
}
selectedDivObj.filters[0].duration=effectduration/1000
selectedDivObj.filters[0].Apply()
}
selectedDivObj.style.display="block"
if (selectedDivObj.filters)
selectedDivObj.filters[0].Play()
selectedDiv=(selectedDiv<totalDivs-1)? selectedDiv+1 : 0
setTimeout("expandboard()",tickspeed)
}

function startbill(){
while (document.getElementById("billboard"+totalDivs)!=null)
totalDivs++
if (document.getElementById("billboard0").filters)
tickspeed+=effectduration
expandboard()
}

if (window.addEventListener)
window.addEventListener("load", startbill, false)
else if (window.attachEvent)
window.attachEvent("onload", startbill)
else if (document.getElementById)
window.onload=startbill



/***********************************************
* Cross browser Marquee II- © Dynamic Drive (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit http://www.dynamicdrive.com/ for this script and 100s more.
***********************************************/

var delayb4scroll=1000 //Specify initial delay before marquee starts to scroll on page (2000=2 seconds)
var marqueespeed=1 //Specify marquee scroll speed (larger is faster 1-10)
var pauseit=1 //Pause marquee onMousever (0=no. 1=yes)?

////NO NEED TO EDIT BELOW THIS LINE////////////

var copyspeed=marqueespeed
var pausespeed=(pauseit==0)? copyspeed: 0
var actualheight=''

function scrollmarquee(){
if (parseInt(cross_marquee.style.top)>(actualheight*(-1)+8))
cross_marquee.style.top=parseInt(cross_marquee.style.top)-copyspeed+"px"
else
cross_marquee.style.top=parseInt(marqueeheight)+8+"px"
}

function initializemarquee(){
cross_marquee=document.getElementById("vmarquee")
cross_marquee.style.top=0
marqueeheight=document.getElementById("marqueecontainer").offsetHeight
actualheight=cross_marquee.offsetHeight
if (window.opera || navigator.userAgent.indexOf("Netscape/7")!=-1){ //if Opera or Netscape 7x, add scrollbars to scroll and exit
cross_marquee.style.height=marqueeheight+"px"
cross_marquee.style.overflow="scroll"
return
}
setTimeout('lefttime=setInterval("scrollmarquee()",50)', delayb4scroll)
}
/**
if (window.addEventListener)
window.addEventListener("load", initializemarquee, false)
else if (window.attachEvent)
window.attachEvent("onload", initializemarquee)
else if (document.getElementById)
window.onload=initializemarquee
*/


var delayb4scroll2=1000 //Specify initial delay before marquee starts to scroll on page (2000=2 seconds)
var marqueespeed2=1 //Specify marquee scroll speed (larger is faster 1-10)
var pauseit2=1 //Pause marquee onMousever (0=no. 1=yes)?

////NO NEED TO EDIT BELOW THIS LINE////////////

var copyspeed2=marqueespeed2
var pausespeed2=(pauseit2==0)? copyspeed2: 0
var actualheight2=''

function scrollmarquee2(){
if (parseInt(cross_marquee2.style.top)>(actualheight2*(-1)+8))
cross_marquee2.style.top=parseInt(cross_marquee2.style.top)-copyspeed2+"px"
else
cross_marquee2.style.top=parseInt(marqueeheight2)+8+"px"
}

function initializemarquee2(){
cross_marquee2=document.getElementById("vmarquee2")
cross_marquee2.style.top=0
marqueeheight2=document.getElementById("marqueecontainer2").offsetHeight
actualheight2=cross_marquee2.offsetHeight
if (window.opera || navigator.userAgent.indexOf("Netscape/7")!=-1){ //if Opera or Netscape 7x, add scrollbars to scroll and exit
cross_marquee2.style.height=marqueeheight2+"px"
cross_marquee2.style.overflow="scroll"
return
}
setTimeout('lefttime2=setInterval("scrollmarquee2()",50)', delayb4scroll2)
}

if (window.addEventListener){
	window.addEventListener("load", initializemarquee, false);
	window.addEventListener("load", initializemarquee2, false);

}
else if (window.attachEvent){
	window.attachEvent("onload", initializemarquee);
	window.attachEvent("onload", initializemarquee2);

}
else if (document.getElementById){
	window.onload=initializemarquee;
	window.onload=initializemarquee2;

}








function init(){
	if((BrowserDetect.browser)!="Explorer"){
		document.getElementById("vmarquee2").style.width="200";
	}
	else{
		setFlash();
	}
	//autofitIframe('stage');
	
}

function goSearch(query){
	var linki
	linki = "asearch.asp?query="+query.replace(" ","%20");
	location = linki;
}
function quick_search(num){
	if(document.general.query.value==""){
		alert('אנא כתוב מילה לחיפוש');
	}
	else{
		goSearch(document.general.query.value);
	}
	if(num==1){
		return false;
	}
}

entity_name = "search";
function submitF(){

	if(document.formi.s_area.value=="0" && document.formi.s_winery.value=="0" && document.formi.s_wkind.value=="0" && document.formi.s_gkind.value=="0" && document.formi.s_rprice_category.value=="0"){
		alert("חובה לבחור לפחות נושא חיפוש אחד");
		return false;
	}						
	else{
		return true;
	}
}

function hp_fade(elem){
	
	if(elem.style.textDecoration=='' ){
		//elem.style.filter='alpha(opacity=70)';
		elem.style.textDecoration='underline';
		
	}
	else{
		elem.style.textDecoration='';
		
	}
}


