$(document).ready(function () { 
  $("a[href$=.flv]").flowplayer("/includes/templates/template_default/flash/flowplayer-3.1.5.swf", {
    // fullscreen button not needed here
    controls: {
        fullscreen: true,
        height: 30
    },
    clip: {
      autoPlay: false,
      autoBuffering: true,
      // optional: when playback starts close the first audio playback
      onBeforeBegin: function() {
      $f("player").close();
      }
  }
  }).each(function() { $f(this).load();  });
  $("a[href$=.mp3]").flowplayer("/includes/templates/template_default/flash/flowplayer-3.1.5.swf", {
    // fullscreen button not needed here
    plugins: {
      audio: { 
        url: '/includes/templates/template_default/flash/flowplayer.audio-3.1.2.swf' 
      }, 
      controls: {
        fullscreen: true,
        height: 30
      }
    },
    clip: {
      autoPlay: false,
      // optional: when playback starts close the first audio playback
      onBeforeBegin: function() {
      $f("player").close();
      }
    }
  }).each(function() { $f(this).load();  });

});

