In the method nextImage, I can't figure out how to access thumbs. It keeps coming back as undefined. (Using Firefox)

I'm relatively new to javascript and this is killing me!!! Please help!

Code JavaScript:
function runPortal(portal_number){
	// there are multiple runPortals on each webpage
 
	this.portal = document.getElementById('portal'+portal_number); // represents the div that holds the images
	this.thumbs = this.portal.getElementsByTagName('a').length; // represents all the images within the div that will be rotated
	this.length = this.thumbs.length; // that's how many images will be rotated
 
 
	// Hide everything
	for (var j=0;j<this.thumbs.length;j++){
		if (j==0) continue; // Don't hide the first one
		this.thumbs[j].childNodes[0].style.display = 'none';
	}
 
 
	this.nextImage = function (){
		// there are a fixed number of images to rotate. Start over
		if (this.i >= this.length){
			this.i = 0;
		}
		// One fades away, the next appears
		Effect.dglPuff(this.thumbs[this.last].childNodes[0], {duration:.6, from:.7});
		Effect.Appear(this.thumbs[this.i].childNodes[0]); 
 
		// iterate to the next image for the next run
		this.last = this.i;
		this.i++;
	}
 
 
	// Set up the image rotator
	// here is where I started guessing
	// thumbs needs to belong to the object rotator, I guess.
 
	this.rotator = new PeriodicalExecuter(this.nextImage, 4); // This object runs the function every 4 seconds
	this.rotator.portal = document.getElementById('portal'+portal_number); // represents the div that holds the images
	this.rotator.thumbs = this.rotator.portal.getElementsByTagName('a'); // represents all the images within the div that will be rotated
	this.rotator.length=this.length;  // that's how many images will be rotated
	this.rotator.i=0; // the counter for what image we're one
	this.rotator.last=0; // the counter for the previous image
 
}