zebraTables = new Class({
	triggerClass: "zebraTable",
	odd: false,
	tables: Object,
	/** INITIALIZE FUNCTION **/
	initialize: function () {
		this.tables = document.getElementsByClassName(this.triggerClass);
		this.tables.each(function(item, index) {
			if(item.getTag()=="ul"){
				rows = item.getElementsByTagName('li');
			}
			else{
				rows = item.getElementsByTagName('tr');
			}
			this.applyRows(rows);
		}.bind(this));
	},
	/** FUNCTION WALKS OVER THE TABLE ROWS **/
	applyRows: function(rows) {
		tableRows = $A(rows);
		tableRows.each(function(row, index){
			if (this.odd == false)
			{
				$(row).addClass('odd');
				this.odd = true;
			}
			else
			{
				this.odd = false;
			}
		}.bind(this));
	}
});

Window.onDomReady(function() {
	var zebraTable = new zebraTables(); 
	zebraTable.initialize;
	});