Skip to content

Instantly share code, notes, and snippets.

@rlisowski
Created September 14, 2011 09:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rlisowski/1216174 to your computer and use it in GitHub Desktop.
Save rlisowski/1216174 to your computer and use it in GitHub Desktop.
mp3 player flowplayer
<!DOCTYPE html>
<!--
This is Flowplayer standalone demo. The fastest way to get started.
You can freely copy things on your site. All demos can be found from:
http://flowplayer.org/demos/
Enjoy!
-->
<head>
<!-- flowplayer scripts should be loaded from your servers NOT from static.flowplayer.org -->
<script type="text/javascript" src="http://static.flowplayer.org/js/flowplayer-3.2.6.min.js"></script>
<!-- some styling for the standalone page. this line can (or must) be removed -->
<link rel="stylesheet" type="text/css" href="/demos/standalone.css"/>
</head>
<body>
<!-- setup player with standard HTML syntax -->
<div id="audio" style="display:block;width:120px;height:30px;" href="http://releases.flowplayer.org/data/fake_empire.mp3"></div>
<script>
$f("audio", "http://releases.flowplayer.org/swf/flowplayer-3.2.7.swf", {
// fullscreen button not needed here
plugins: {
controls: {
"height": 30,
"width": 120,
"borderRadius": "0px",
"timeColor": "#ffffff",
"bufferGradient": "none",
"backgroundColor": "rgba(0, 0, 0, 0)",
"volumeSliderGradient": "none",
"timeBorderRadius": 20,
"progressGradient": "none",
"time": false,
"volumeColor": "#4599ff",
"tooltips": {
"marginBottom": 5,
"buttons": false },
"opacity": 1,
"timeFontSize": 12,
"volumeSliderColor": "#ffffff",
"border": "0px",
"bufferColor": "#a3a3a3",
"buttonColor": "#ffffff",
"autoHide": {
"enabled": true,
"hideDelay": 500,
"hideStyle": "fade",
"mouseOutDelay": 500,
"hideDuration": 400,
"fullscreenOnly": true },
"backgroundGradient": "none",
"display": "block",
"sliderBorder": "1px solid rgba(128, 128, 128, 0.7)",
"buttonOverColor": "#ffffff",
"url": "flowplayer.controls-3.2.5.swf",
"fullscreen": false,
"timeBgColor": "rgb(0, 0, 0, 0)",
"scrubberBarHeightRatio": 0.2,
"bottom": 0,
"buttonOffColor": "rgba(130,130,130,1)",
"zIndex": 1,
"sliderColor": "#000000",
"scrubberHeightRatio": 0.6,
"tooltipTextColor": "#ffffff",
"spacing": {
"time": 6,
"volume": 8,
"all": 2 },
"sliderGradient": "none",
"timeBgHeightRatio": 0.8,
"volumeSliderHeightRatio": 0.6,
"timeSeparator": " ",
"name": "controls",
"volumeBarHeightRatio": 0.2,
"left": "50pct",
"tooltipColor": "rgba(0, 0, 0, 0)",
"durationColor": "#b8d9ff",
"play": false,
"progressColor": "#4599ff",
"timeBorder": "0px solid rgba(0, 0, 0, 0.3)",
"scrubber": false,
"volumeBorder": "1px solid rgba(128, 128, 128, 0.7)",
"builtIn": false,
"margins": [2, 12, 2, 12]
}
},
clip: {
autoPlay: true,
// play in loop
onFinish: function() {
$f("audio").stop();
$f("audio").play();
}
}
});
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment