// JavaScript Document
$(document).ready(function(){
						  
//H1
    $('h1').flash(
        { 
            src: '/flash/jfr.swf', 
			Wmode: 'transparent',
            flashvars: {
                css: [
                    '* { color: #D72226; }',
                    'a, a:link, a:visited, a:active { color: #666666; text-decoration: none; }',
                    'a:hover { color: #0099CC; text-decoration: underline; }'
                ].join(' ')
            }
        },
        { version: 7 },
        function(htmlOptions) {
            htmlOptions.flashvars.txt = this.innerHTML;
            this.innerHTML = '<div>'+this.innerHTML+'</div>';
            var $alt = $(this.firstChild);
            htmlOptions.height = $alt.height();
            htmlOptions.width = $alt.width();
            $alt.addClass('alt');
            $(this)
                .addClass('flash-replaced')
                .prepend($.fn.flash.transform(htmlOptions));						
        }
    );

//H2
	    $('h2').flash(
        { 
            src: 'flash/jfr.swf',
			Wmode: 'transparent',
            flashvars: { 
                css: [
                    '* { color: #fff;}',
                    'a { color: #333333; text-decoration: none; }',
                    'a:hover { color: #0099CC; text-decoration: underline; }'
                ].join(' ')
            }
        },
        { version: 7 },
        function(htmlOptions) {
            htmlOptions.flashvars.txt = this.innerHTML;
            this.innerHTML = '<div>'+this.innerHTML+'</div>';
            var $alt = $(this.firstChild);
            htmlOptions.height = $alt.height();
            htmlOptions.width = $alt.width();
            $alt.addClass('alt');
            $(this)
                .addClass('flash-replaced')
                .prepend($.fn.flash.transform(htmlOptions));						
        }
    );


//H4
		$('h4').flash(
        { 
            src: 'flash/jfr.swf',
			Wmode: 'transparent',
            flashvars: { 
                css: [
                    '* { color: #fff;}',
                    'a { color: #0099CC; text-decoration: none; }',
                    'a:hover { text-decoration: underline; }'
                ].join(' ')
            }
        },
        { version: 7 },
        function(htmlOptions) {
            htmlOptions.flashvars.txt = this.innerHTML;
            this.innerHTML = '<div>'+this.innerHTML+'</div>';
            var $alt = $(this.firstChild);
            htmlOptions.height = $alt.height();
            htmlOptions.width = $alt.width();
            $alt.addClass('alt');
            $(this)
                .addClass('flash-replaced')
                .prepend($.fn.flash.transform(htmlOptions));						
        }
    );

    $('#triangle').flash(
        { src: 'flash/triangle.swf',
		Wmode: 'transparent',
          width: 180,
          height: 100 }
    		,
        { version: 8 }
	);
	    $('#trianglelarge').flash(
        { src: 'flash/triangle.swf',
		Wmode: 'transparent',
          width: 750,
          height: 350 }
    		,
        { version: 8 }
	);
});

