function nl2br (str, is_xhtml) {
		// http://kevin.vanzonneveld.net
		// +   original by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
		// +   improved by: Philip Peterson
		// +   improved by: Onno Marsman
		// +   improved by: Atli Þór
		// +   bugfixed by: Onno Marsman
		// +      input by: Brett Zamir (http://brettz9.blogspot.com)
		// +   bugfixed by: Kevin van Zonneveld (http://kevin.vanzonneveld.net)
		// *     example 1: nl2br('Kevin\nvan\nZonneveld');
		// *     returns 1: 'Kevin<br />\nvan<br />\nZonneveld'
		// *     example 2: nl2br("\nOne\nTwo\n\nThree\n", false);
		// *     returns 2: '<br>\nOne<br>\nTwo<br>\n<br>\nThree<br>\n'
		// *     example 3: nl2br("\nOne\nTwo\n\nThree\n", true);
		// *     returns 3: '<br />\nOne<br />\nTwo<br />\n<br />\nThree<br />\n'
 
		var breakTag = '';
 
		breakTag = '<br />';
		if (typeof is_xhtml != 'undefined' && !is_xhtml) {
				breakTag = '<br>';
			}
 
		return (str + '').replace(/([^>]?)\n/g, '$1'+ breakTag +'\n');
	}


jQuery(document).ready(function(){ 
		
	var quote_the = '';
	var quote_by = '';
	var quoted_where = '';
 
	// Live preview
	jQuery(document).keyup(function(e)	{ 
		
		quote_the = $('#quote_the').val();
		quote_by = $('#quote_by').val();
		quoted_where = $('#quoted_where').val();
		
		jQuery('#quote_preview blockquote').html('"'+ nl2br(quote_the, true) + '"');
		jQuery('#quote_preview bold').html(quote_by + ",");
		jQuery('#quote_preview cite').html(quoted_where);
		
		});


});