
function sizeSmall(Divname,fontsize)
{
	fontSize=document.getElementById(Divname);
	fontSize.style.fontSize=fontsize;
}
function DivClass(Divname,ClassSet)
{
	fontSize=document.getElementById(Divname);
	fontSize.className=ClassSet;
}
 function ImageFlash(picSrcString,imgLink,TextString)
{
	var focus_width=257;
	var focus_height=182;
	var text_height=16;
	var swf_height = focus_height+text_height
	 
	var pics=picSrcString;
	var links=imgLink;
	var texts=TextString;
	 
	document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" width="'+ focus_width +'" height="'+ swf_height +'">');
	document.write('<param name="allowScriptAccess" value="sameDomain"><param name="movie" value="focus.swf"><param name="quality" value="high"><param name="bgcolor" value="#F0F0F0">');
	document.write('<param name="menu" value="false"><param name=wmode value="opaque">');
	document.write('<param name="FlashVars" value="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'">');
	document.write('<embed src="pixviewer.swf" wmode="opaque" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'" menu="false" bgcolor="#F0F0F0" quality="high" width="'+ focus_width +'" height="'+ focus_height +'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');  document.write('</object>');
 }
  function IsHotImage(picSrcString,imgLink)
{
	var focus_width=604
	var focus_height=111
	var text_height=0
	var swf_height = focus_height+text_height
	 
	var pics=picSrcString;
	var links=imgLink;
	var texts="";
	 
	document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" width="'+ focus_width +'" height="'+ swf_height +'">');
	document.write('<param name="allowScriptAccess" value="sameDomain"><param name="movie" value="focus.swf"><param name="quality" value="high"><param name="bgcolor" value="#F0F0F0">');
	document.write('<param name="menu" value="false"><param name=wmode value="opaque">');
	document.write('<param name="FlashVars" value="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'">');
	document.write('<embed src="pixviewer.swf" wmode="opaque" FlashVars="pics='+pics+'&links='+links+'&texts='+texts+'&borderwidth='+focus_width+'&borderheight='+focus_height+'&textheight='+text_height+'" menu="false" bgcolor="#F0F0F0" quality="high" width="'+ focus_width +'" height="'+ focus_height +'" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />');  document.write('</object>');
 }
    var delta=0.5
    var collection;
    function floaters() {
        this.items    = [];
        this.addItem    = function(id,x,y,content)
                  {
                    document.write('<DIV id='+id+' style="Z-INDEX: 10; POSITION: absolute;  width:80px; height:300px;left:'+(typeof(x)=='string'?eval(x):x)+';top:'+(typeof(y)=='string'?eval(y):y)+'">'+content+'<div class="Divcolse"'+' onclick='+id+'.style.visibility="hidden"'+'>¹Ø±Õ</div>'+'</DIV>');
                    var newItem                = {};
                    newItem.object            = document.getElementById(id);
                    newItem.x                = x;
                    newItem.y                = y; 
                    this.items[this.items.length]        = newItem;
                  }
        this.play    = function()
                  {
                    collection                = this.items
                    setInterval('play()',10);
                  }
        }
        function play()
        {
            if(screen.width<=800)
            {
                for(var i=0;i<collection.length;i++)
                {
                    collection[i].object.style.display    = 'none';
                }
                return;
            }
            for(var i=0;i<collection.length;i++)
            {
                var followObj        = collection[i].object;
                var followObj_x        = (typeof(collection[i].x)=='string'?eval(collection[i].x):collection[i].x);
                var followObj_y        = (typeof(collection[i].y)=='string'?eval(collection[i].y):collection[i].y); 
                if(followObj.offsetLeft!=(document.body.scrollLeft+followObj_x)) {
                    var dx=(document.body.scrollLeft+followObj_x-followObj.offsetLeft)*delta;
                    dx=(dx>0?1:-1)*Math.ceil(Math.abs(dx));
                    followObj.style.left=followObj.offsetLeft+dx;
                    } 
                if(followObj.offsetTop!=(document.body.scrollTop+followObj_y)) {
                    var dy=(document.body.scrollTop+followObj_y-followObj.offsetTop)*delta;
                    dy=(dy>0?1:-1)*Math.ceil(Math.abs(dy));
                    followObj.style.top=followObj.offsetTop+dy;
                    }
                followObj.style.display    = '';
            }
        }
var xPos = 500;
var yPos = 400;
var step = 1;
var delay = 30; 
var width,height,Hoffset,Woffset;
var y = 1;
var x = 1;
var interval;
var theIs=true;

function changePos() 
{
if(theIs)
{
width = document.body.clientWidth;
  height = document.body.clientHeight;
  Hoffset = img.offsetHeight;
  Woffset = img.offsetWidth;
  if (y) 
  {
    yPos = yPos + step;
  }
  else 
  {
    yPos = yPos - step;
  }
  if (yPos < 0) 
  {
    y = 1;
    yPos = 0;
  }
  if (yPos >= (height - Hoffset)) 
  {
    y = 0;
    yPos = (height - Hoffset);
  }
  if (x) 
  {
    xPos = xPos + step;
  }
  else 
  {
    xPos = xPos - step;
  }
  if (xPos < 0) 
  {
    x = 1;
    xPos = 0;
  }
  if (xPos >= (width - Woffset)) 
  {
    x = 0;
    xPos = (width - Woffset);
  }
  img.style.left = xPos + document.body.scrollLeft;
  img.style.top = yPos + document.body.scrollTop;
}
  
}

function start() 
{
	interval = setInterval('changePos()', delay);
}
function isGo()
{
	theIs=true;
}
function isBack()
{
	theIs=false;
}
function pause_resume() 
{
    clearInterval(interval);
}
function winOpen(Url,width,height,scrollbar,resize)
{
// Url 
// widht
// height 
// scrollbar 0 yes 1 no 
// resize 0 true 1 false

ow = width;
oh = height;
os = scrollbar;
or = resize;
var xposition=0; 
var yposition=0;
if ((parseInt(navigator.appVersion) >= 4 ))
  {
    xposition = (screen.width - width) / 2;
    yposition = (screen.height - height-25) / 2;
  }
  window.open (Url,"","width ="+ow+",height="+oh+",scrollbars = "+os+",resizable="+or+",left="+xposition+",top="+yposition );
} 

