
	var debugging = false;

	/*
	Set it up so that namespace is established
	Write "coverWith" function with highest top of 
		covering DIV being page top of underlying DIV, width same, 
		height as needed but no less than underlying DIV
	*/


function colorSidebar() {
		// provide for input: covered elem, covering elem
	var coveredElemName   = 'main-content';
	var styleWidth        = 'width';
	var styleHeight       = 'height';
	var coveringElemName  = 'sidebar-content';
		//
	var coveredElemObj    = new returnObj(coveredElemName);
	var coveringElemObj   = new returnObj(coveringElemName);
		// FF and IE sometimes return percentage, Opera returns px?!?
	var coveredElemWidth  = getStyle(coveredElemObj, styleWidth);
	var coveredElemHeight = getStyle(coveredElemObj, styleHeight);
		//
	var coveredElemLeft  = findLeft(coveredElemObj);
	var coveredElemTop   = findTop(coveredElemObj);
		//
	if (debugging) {
		var x                 = styleWidth + ' of element{'+ coveredElemName +'} is [';
		    x                += coveredElemWidth + '], which is a '+ typeof(coveredElemWidth);
		alert (x);
		    x                 = 'left position of element{' + coveredElemName + '} is [';
		    x                += coveredElemLeft + ']. top is ['+ coveredElemTop +']';
		alert(x);
		var x                 = styleHeight + ' of element{'+ coveredElemName +'} is [';
		    x                += coveredElemHeight + '], which is a '+ typeof(coveredElemHeight);
		alert (x);
		}
		//
	// coveringElemObj.style.left   = coveredElemLeft + 'px';
	// coveringElemObj.style.top    = coveredElemTop  + 'px';
	// coveringElemObj.style.width  = coveredElemWidth;  // width  already has "px" or "%" following...
	coveringElemObj.style.height    = coveredElemHeight; // height already has "px" or "%" following...
	}


function getStyle(objElem, strCssRule){
    var strValue = "";
	var strObj = null;
	var p1 = null;
    if(window.getComputedStyle){
        strValue = document.defaultView.getComputedStyle(objElem, null).getPropertyValue(strCssRule);
    	}
    else if(objElem.currentStyle){
        strCssRule = strCssRule.replace(/\-(\w)/g, function (strMatch, p1){
            return p1.toUpperCase();
        	});
        strValue = objElem.currentStyle[strCssRule];
    	}
    return strValue;
}



function findLeft(objElem) {
	// If numeric answer, add 'px' before returning
	var curleft = 0;
	if (objElem.offsetParent) {
		while (objElem.offsetParent) {
			curleft += objElem.offsetLeft
			objElem = objElem.offsetParent;
			}
		}
	else if (objElem.x) { curleft += objElem.x; }
		//
	return curleft;
	}

function findTop(objElem) {
	// If numeric answer, add 'px' before returning
	var curtop = 0;
	if (objElem.offsetParent) {
		while (objElem.offsetParent) {
			curtop += objElem.offsetTop
			objElem = objElem.offsetParent;
			}
		}
	else if (objElem.y) { curtop += objElem.y; }
		//
	return curtop;
	}



function returnObj(id) {
	if (document.getElementById) {
  		this.obj = document.getElementById(id);
//		this.style = document.getElementById(id).style;
//		if (debugging) {alert('getElementById for ' + id); }
		}
	else if (document.all) {
		this.obj = document.all[id];
//		this.style = document.all[id].style;
//		if (debugging) { alert('all for ' + id); }
		}
	else if (document.layers) {
   		this.obj = document.layers[id];
//  		this.style = document.layers[id];
//		if (debugging) { alert('layers for ' + id); }
		}
	else {
//		if (debugging) { alert('No DOM?? for ' + id); }
		}
		// Will not work unless we explicitly 'return' as below
	return this.obj;
	}


function q(num) {
	switch (num){
		case 1:
			var q  = 'Purchase by clicking on the button.<br />Only $25 plus postage.';
			    q += '';
			// return overlib(q, WIDTH, 250, TEXTSIZE, 2, OFFSETY, -20, CSSCLASS, 
							  // "OverLibAlt", CAPTIONFONTCLASS, 'OverLibFont');
			break;
		case 2:
			var q  = 'Interest in alternative sources of energy is increasing worldwide.<br><strong>Car';
			    q += 'bon markets</strong> have produced new opportunities:<br>How can these opportunit'
				q += 'ies be realized? <strong>Investors</strong> today<br>are seeing more ASE projects';
				q += ', and they want to know if those projects<br>&ldquo;pencil out&rdquo;. <strong>Co';
				q += 'mpanies</strong> that want to offer their customers<br>a carbon neutral experienc';
				q += 'e wonder how. <strong>Project developers</strong><br>want accurate, lively, cogen';
				q += 't text in their prospectus.<br><br>Do you have a bioenergy challenge?<br>Visit ou';
				q += 'r consulting website and contact us for assistance.<br><em>We strive for excellen';
				q += 'ce.</em>';
			    q += '';
			return overlib(q, WIDTH, 550, TEXTSIZE, 3, OFFSETY, -300, CAPTIONFONTCLASS, 'OverLibFont');
			break;
		case 3:
			var q  = 'Share this resource with others on StumbleUpon, Digg, Delicious or other social m';
				q += 'edia sites.';
			    q += '';
			return overlib(q, WIDTH, 350, TEXTSIZE, 2, OFFSETY, -150, TEXTFONTCLASS, 'OverLibAlt');
			break;
		case 4:
			var q  = 'The class will be April 23<sup>rd</sup>, in Hawaii! Can&rsquo;t attend?<br>Take a lo';
				q += 'ok anyway and tell us of your interest. If we<br>know you&rsquo;d like to take a cla';
			    q += 'ss, we may be able to<br>have an event nearer to you soon!';
			    q += '';
			return overlib(q, TEXTSIZE, 2, OFFSETY, -50, OFFSETX, 100, TEXTFONTCLASS, 'OverLibAlt');
			break;
		case 5:
			var q  = 'Oops! See the link for information on<br>elephant dung and biogas production&hellip;';
			    q += '';
			return overlib(q, TEXTSIZE, 2, OFFSETY, -50, OFFSETX, 100, TEXTFONTCLASS, 'OverLibAlt');
			break;
		default : 
			var q = 'Number not supported!';
			return overlib(q, WIDTH, 80);
			break;
	}
}
