Version: 1.00, by ericgtr
Developer Last Online: Feb 2022
Category: Show Thread Enhancements -
Version: 4.0.3
Rating:
Released: 04-16-2010
Last Update: 05-17-2010
Installs: 88
Template Edits
Re-useable Code
No support by the author.
This is a simple modification that will embed an "attached" MP3 player so the file can be played inline. It uses a simple flash player from Google. There are many MP3 player mods but none that I could find that would actually play an attached file and in my community this was a the most missed feature since the upgraded to 4.x.
Unzip and then upload the attached audio_player.swf to your server, then modify the path where it says http://www.YOURSITE.com accordingly.
Open up postbit_attachment and add this at the very bottom:
HTML Code:
<!-- Embed Player --><vb:if condition="$show['member']"><embed type="application/x-shockwave-flash" src="http://www.YOURSITE.com/audio-player.swf?audioUrl=attachment.php?{vb:raw session.sessionurl}attachmentid={vb:raw attachment.attachmentid}&d={vb:raw attachment.dateline}" width="400" height="27" allowscriptaccess="never" quality="best" bgcolor="#ffffff" wmode="window" flashvars="playerMode=embedded" /></vb:if><BR /><vb:if condition="$show['guest']"><a href="/register.php">Register for free</a> today to download files or play them directly in our embedded media player
</vb:if><!-- /Embed Player -->
I have added a register option for guests, if you have attachments viewable by guests though feel free to strip that out of this code.
very nice is it possible to get player and keep our web-server
cos it may be fast loading
I haven't tried but my guess is you can probably take grab the player from http://www.google.com/reader/ui/3247...dio-player.swf then upload it to your server and use it that way. I can't guarantee that it will work but I don't see why it wouldn't. Of course, being Google I think it's probably going to have a better up-time percentage than most sites.
Quote:
Originally Posted by sulasno
Do I upload a mp3 to the forum or will posting a link triggers the player ?
Quote:
Originally Posted by COL NIL SATIS
where does this show mate???? i have put the code in but nothing is showing??? any ideas
Once the MP3 is uploaded it will show in the post below where the attachment is normally shown. Make sure the code is applied to the template(s) you are using.
I haven't tried but my guess is you can probably take grab the player from http://www.google.com/reader/ui/3247...dio-player.swf then upload it to your server and use it that way. I can't guarantee that it will work but I don't see why it wouldn't. Of course, being Google I think it's probably going to have a better up-time percentage than most sites.
Once the MP3 is uploaded it will show in the post below where the attachment is normally shown. Make sure the code is applied to the template(s) you are using.
uploading google player to server and adjusting code to link to it does work
Code:
<!-- Embed Player -->
<vb:if condition="$show['member']">
<embed type="application/x-shockwave-flash" src="/location of player on your server/audio-player.swf?audioUrl=attachment.php?{vb:raw session.sessionurl}attachmentid={vb:raw attachment.attachmentid}&d={vb:raw attachment.dateline}" width="400" height="27" allowscriptaccess="never" quality="best" bgcolor="#ffffff" wmode="window" flashvars="playerMode=embedded" />
</vb:if>
<BR />
<vb:if condition="$show['guest']">
<a href="/register.php">Register for free</a> today to download files or play them directly in our embedded media player
</vb:if>
<!-- /Embed Player -->