
var popwindow
var thistoolbar="no"
var thislocation="no"
var thisdirectories="no"
var thisstatus="no"
var thismenubar="no"
var thisscrollbars="yes"
var thisresizable="no"
// var thisurl="popupwindow.html"
var thiswidth="550"
var thisheight="530"
var thisdirection="horitop"

var thistopposition="207"
var thisleftposition="351"
var thisfullscreen="no"
var pause=20
var stepfactor=15
var stepx
var stepy
var marginpadding=30
var startleft=0
var endleft=0
var starttop=0
var endtop=0
var marginleft=0
var margintop=0
var marginright
var marginbottom
var timer
var i_shakemax=3
var i_shakenow=0
var newurl=""

function initpopup(popupurl) {
newurl=popupurl	
valuesstaticandshake()
openpopup()
}

function valuesstaticandshake() {
marginright=screen.width
marginbottom=screen.height
startleft=(marginright-thiswidth)/2
starttop=(marginbottom-thisheight)/2
}

function openpopup() {
popwindow=window.open(newurl, "newwindow", "toolbar="+thistoolbar+",location="+thislocation+",directories="+thisdirectories+",status="+thisstatus+",menubar="+thismenubar+",scrollbars="+thisscrollbars+",resizable="+thisresizable+",width="+thiswidth+",height="+thisheight+",top="+starttop+",left="+startleft+",fullscreen="+thisfullscreen+"")
popwindow.focus()
}
