// JavaScript Document
(function($) {

	$.fn.quotatorAll = function(options){
		var container = this;
		var defaults = 
		{
			speed : 4000,
			json : "./quotations.js"
		}
		
		var options = $.extend(defaults, options);
		
		var quotes_json = options.json;
		var quotes;
		var tempS ="" ;
		
		$.getJSON(quotes_json, function(data) {
			var quotesobject = eval(data.quotes);
			var index = 0;
			
			for (index=0;index<=quotesobject.length - 1;index++) {
				tempS = tempS + "<div id='quotes'>" + quotesobject[index].quote + "<div id='author'>" + quotesobject[index].author + "</div></div>";
			}

			container.html(tempS);
	
		});
		
		return container;
	}
	
})(jQuery);

