[code]
function print_r(variable,lvl,history) {
	var space = '&nbsp;&nbsp;';
	var linef = '<br/>';
	var output = '';
	if(typeof(history) == 'undefined') {
		var history = 'this';
	}
	if(typeof(lvl) == 'undefined') {
		var lvl = 0;
	}
	if(lvl==0) {
		output = '<span style="color:#00f;">' + history + '</span> = ';
	}
	var ws = '';
	for(var x = 0;x < lvl;x++) {
		ws += space;
	}
	
	if(variable == null) {
		return output+'<em title="null '+history+' = null;" style="color:#408;">null</em>'+((lvl==0)?';':'');
	} else if(typeof(variable) == 'object') {
		if(variable instanceof Array) {
			output += '['+linef;
			for(var x = 0;x<variable.length;x++) {
				output += ws+space+'<span style="color:#000;">'+x+'</span>:'+print_r(variable[x],lvl+1,history+'['+x+']')+','+linef;
			}
			return output + ws + ']'+((lvl==0)?';':'');
		} else {
			output += '{'+linef;
			for(var key in variable) {
				output += ws+space+'<span style="color:#00f;">'+key+'</span>:'+print_r(variable[key],lvl+1,history+'.'+key)+','+linef;
			}
			return output+ws+'}'+((lvl==0)?';':'');
		}
	} else if(typeof(variable) == 'string') {
		return output+'<span title="string '+history+' = &quot;'+variable.toString()+'&quot;;" style="color:#F00;">"'+variable.toString()+'"</span>'+((lvl==0)?';':'');
	} else if(typeof(variable) == 'function') {
		return output+'<span title="function '+history+'();" style="color:#070">'+variable.toString().replace(/\{((\n|\r|.)*)\}/gi,'{}').replace(/^function \(/gi,'function(')+'</span>'+((lvl==0)?';':'');
	} else if(typeof(variable) == 'number') {
		return output+'<span title="number '+history+' = '+variable.toString()+';" style="color:#000">'+variable.toString()+'</span>'+((lvl==0)?';':'');
	} else if(typeof(variable) == 'undefined') {
		return output+'<em title="undefined '+history+' = undefined;" style="color:#f66;">undefined</em>'+((lvl==0)?';':'');
	} else if(typeof(variable) == 'boolean') {
		return output+'<em title="boolean '+history+' = '+(variable?'true':'false')+';" style="color:#070;">'+(variable?'true':'false')+'</em>'+((lvl==0)?';':'');
	} else {
		return output+'<span title="'+typeof(variable)+' '+history+' = new '+typeof(variable)+';" style="color:#888;">('+typeof(variable)+')</span>'+((lvl==0)?';':'');
	}
}

[/code]

Heb syntax highlighting niet aan kunnen zetten met < ? en ? >: de class.bbcode.php gaf errors!