function pgChaser(sLayerId, iTopOffset, iSlideTime, iCeiling, iFloor) {
this.chaserDiv = null
this.layerId = sLayerId
this.topOffset = iTopOffset
this.slideTime = iSlideTime
this.ceiling = iCeiling
this.floor = iFloor
pgChaser.registry[pgChaser.registry.length] = this
}
pgChaser.isIE = window.clientInformation ? true : false
pgChaser.isN4 = document.layers ? true : false
pgChaser.isN6 = navigator.appName == "Netscape" && parseInt(navigator.appVersion) >= 5
pgChaser.isO5 = navigator.userAgent.indexOf("Opera") != -1 && parseInt(navigator.appVersion) >= 4
pgChaser.registry = new Array( )
pgChaser.callRate = 10
window.setInterval("pgChaser.timer( )", pgChaser.callRate)
pgChaser.timer = function() {
for (var i = 0; chObj = this.registry[i]; i++) {
if (!chObj.chaserDiv) chObj.attemptLoad()
if (chObj.chaserDiv) chObj.main()
}
}
pgChaser.prototype.attemptLoad = function() {
var chDiv = null
if (pgChaser.isN6 || pgChaser.isO5) chDiv = document.getElementById(this.layerId)
else if (pgChaser.isIE) chDiv = document.all[this.layerId]
else if (pgChaser.isN4) chDiv = document.layers[this.layerId]
if (chDiv && chDiv != null) {
this.chaserDiv = chDiv
}
}
pgChaser.prototype.main = function( )
{
this.currentY = this.getCurrentY()
var scrollTop = pgChaser.getWindowScroll() 
var newTargetY = scrollTop + this.topOffset
var floor = pgChaser.getDocumentHeight() - this.floor 
newTargetY = Math.max( newTargetY, this.ceiling)
if (!pgChaser.isO5) newTargetY = Math.min(newTargetY, floor)
if ( this.currentY != newTargetY ) {
if ( newTargetY != this.targetY ) {
this.targetY = newTargetY
this.slideInit( )
}
this.slide( )
}
}
pgChaser.prototype.slideInit = function( )
{
this.A = (this.targetY - this.currentY ) / this.slideTime / this.slideTime
this.startT = (new Date()).getTime()
this.startP = this.getCurrentY()
this.D = this.targetY - this.startP 
}
pgChaser.prototype.slide = function( )
{
var elapsed = (new Date()).getTime() - this.startT
if (elapsed < this.slideTime) {
this.moveTo(this.D - (Math.round(Math.pow(this.slideTime - elapsed, 2) * this.A)) + this.startP)
}
}
pgChaser.prototype.moveTo = function(ny) {
if (pgChaser.isN4) this.chaserDiv.top = ny
else this.chaserDiv.style.top = ny + "px"
}
pgChaser.prototype.getCurrentY = function() {
var n = pgChaser.isN4 ? this.chaserDiv.top : parseInt(this.chaserDiv.style.top)
return isNaN(n) ? 0 : n
}
pgChaser.getWindowScroll = function() {
if (pgChaser.isIE) return document.body.scrollTop
else return window.pageYOffset
}
pgChaser.getDocumentHeight = function() {
if (pgChaser.isO5) return 0 
else if (pgChaser.isIE) return Math.max(document.body.scrollHeight, document.body.offsetHeight)
else return window.document.height
}