Plugin Author
Fabian
(@fabifott)
This is easily done with HTML5. See http://www.w3schools.com/html5/html5_audio.asp .
You have to put the HTML code into your File Browser File Template.
Hi and thanks for your answer.
I did try so, but the problem is this basic player is prebuffering all listed tracks. Since the apache server allow only 3 connections per client, user can’t listen to some song until others have finished buffering.
Is there a way to prebuffer only when play is clicked?
Thanks again for your help.
Still no luck.
I’m now using WPaudio, but it won’t get my code within the filebrowser.
If anybody has a solution to setup a simple player for preview purposes, let me know.
Thanks !
Hey kahuitel… try to add preload=”none” to your audio tag. So would look like:
<audio src="yousourcelink.mp3" preload="none"></audio>
That should stop the page from loading the audio automatically.
Hi !
Thanks for your help ! I’ve sorted it out yesterday night using this template :
<div class="wpfilebase-attachment">
<div class="wpfilebase-fileicon"><a href="%file_url%" title="Download %file_display_name%"><img align="middle" src="%file_icon_url%" alt="%file_display_name%" height="80"/></a></div>
<div class="wpfilebase-rightcol">
<div class="wpfilebase-filetitle">
<a href="%file_url%" title="Download %file_display_name%"><strong>%file_name%</a><br />
%file_info/tags/id3v1/artist%<br />
%file_info/tags/id3v1/title%<br />
%file_info/tags/id3v1/album%</strong><br />
<!-- IF %file_post_id% AND %post_id% != %file_post_id% --><a href="%file_post_url%" class="wpfilebase-postlink">%'View post'%</a><!-- ENDIF -->
</div>
</div>
<div class="wpfilebase-fileinfo">
%file_info/playtime_string%<br />
%file_info/bitrate%<br />
%file_size%<br />
<strong>%file_hits% %'Downloads'%</strong><br />
</div>
<audio id="audio-player" src="%file_url%" type="audio/mp3" controls="controls" preload="none" style="width: 420px;"></audio>
</div>
SOLVED
yup… got the preload none in there, nice work!
I hope it’ll help some peepz! Thanks for your help david.