/*-------------------------------------------------
Compatible with jQuery 1.3.2
Requires jQuery.flash
written by Andrew Gruner
-------------------------------------------------*/
(function($)
{
	$.fn.flashtxt = function(htmlOptions, pluginOptions)
	{
		// Set the options.
		var htmlOptions = $.extend({}, $.fn.flashtxt.defaults.htmlOptions, htmlOptions);
		var pluginOptions = $.extend({}, $.fn.flashtxt.defaults.pluginOptions, pluginOptions);

		// Go through the matched elements and return the jQuery object.
		return this.each(function()
		{
			var $this = $(this);
			
			// get the object's text for passing to flash
			htmlOptions.flashvars.txt = $this.html();
			
			// call the flash plugin with our new options
			$this.flash(htmlOptions, pluginOptions);
		});
	};

	// Public defaults.
	$.fn.flashtxt.defaults = 
	{
		htmlOptions:
		{
			wmode: 'transparent',
			flashvars: {}
		},
		pluginOptions:
		{
			version: 9,
			update: false // don't replace anything if flash is not installed
		}
	};
})(jQuery);