Closed (fixed)
Project:
MP3 Player
Version:
6.x-1.x-dev
Component:
Miscellaneous
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
3 Mar 2009 at 15:22 UTC
Updated:
10 Dec 2010 at 01:48 UTC
I administer a church website and we post MP3 files or the chruch service online. I would really like to use this module, but the only thing that is stopping me from using it is that in addition to the player showing up and allowing users to stream the audio file from the site, I also need to display a download link for the MP3 file. That way, if the person doesn't have time sit and stream it from the website, they can download it and put it on their iPod or other MP3 player.
Comments
Comment #1
jdelaune commentedYou could do this quite easily with a view, or custom template. We use a custom template on the HTB website ( http://www.htb.org.uk ). I'm more inclined to direct people to do that rather than modify the module to display it because they will have greater control over the theming and location of the link.
Let me know what you think.
Comment #2
CandC540 commentedThanks for the hint on how to get this working. I ended up using Contemplate and got it working the way that I wanted it to.
Comment #3
mundox commentedI am trying to do a similar thing. Would you elaborate on this solution? Cheers
Comment #4
kjv1611 commentedI think you may want to check out the Audio module. It's not as customizeable as being able to just stick this player in where you want it, but it has the Audio Import, Audio Player (you can use the same audio player), and download link, GetID3 info, etc, all in one deal. All you do is import your audio files, add what details necessary to them (if the getId3 part doesn't work right, or if you want to add additional info, and submit. Viola! You've got a node that has the player, download link, summary if you like, etc. It really does work well for sermons.
Another option would be to use the filefield module to set a link to your mp3 file location (I think) - I think I got it to do this when I was trying to get the player to point to a file on my site...
And yet another option is to use the swf tools. This is one I may eventually go with, but you have to jump into the code a little bit to get it to work - basically, it does pretty much the same thing as this module, I think.
Easiest overall on my experience is the audio module.
Comment #5
CandC540 commentedHere's what I did: http://www.wilshireave.com/sermons
I used the MP3 Player module, CCK, Views, and Contemplate.
To keep it simple, follow the steps for MP3 Player to add it to your node type, use contemplate to display the player and download links.
Comment #6
kjv1611 commentedHey, I like that method. It looks nice, neat, and simple - to the point, and not overly complex. And using that method, like you did, I suppose you can customize the node anyway you want. Thanks for posting!
By the way, you need to add your church site over at: http://groups.drupal.org/node/2700 (of course, totally voluntary, but it's a great idea for churches to be able to learn from each other).
Comment #7
jdelaune commentedYup ConTemplate is a good alternative if you don't want to manually edit the template files. Thanks for sharing.
Comment #8
mundox commentedI have managed to accomplish this by doing the following:
Installed FileForce module.
Edited the node-audio-tpl.php file (for custom use of mp3 player module) and inserted the following piece of code:
<a href="?q=download/<?php print $node->field_mp3['0']['filepath']; ?>">DOWNLOAD</a>You can stick that in a div.Since I am not using clean URLs hence the ?q= before the link starts.
If you follow FileForce documentation than you'll know why there's the entrydownload/ before the link.
This works on Firefox and Safari.
Cheers for a great bunch of modules that come together nicely!
Comment #9
jdelaune commentedAwesome
Comment #11
Sturmey commentedThis has only taken me 3 months to figure out since people say "I just used this", or "just use contemplate" Well almost all of what I found wasn't helpful, so here is what I did so the next person can actually figure this out.
create a new tpl.php for your node.
>find the node.tpl.php file in your theme, copy it and rename it node-content_type.tpl.php (replace content_type with the name of your content type)
edit the file and find
change it so that it reads
What this does
create a div with a class mp3 so that you can format it with css
add a link using the variable 'filepath'
label the link with the variable 'filename'
you could also put "download" or "get the file"
in my style.css file I added this class
This adds a picture that says "download" to the left of the link text on mp3 links only.
For what it's worth, the contemplate module was a bigger headache than it was worth, although it did eventually lead me to reading a "how to" that steered me to creating my own tpl.php file for this.
If you want to see what it finally looks like, http://reinland.ca/plautdietsch
Comment #12
CandC540 commentedI'm not trying to be mean or anything, but you could have saved yourself three months worth of frustration by replying with a simple how did you do it. I'm glad that you figured it out in the end, but next time just ask a question and you may just get an answer.
Comment #13
Sturmey commentedSince most of the posts that had anything to do with mp3player module were more than a year old, I thought the likelihood of getting a timely response would be poor.
But since you offered:
Have you gotten the RSS feed to show the link and file in iTunes?
If so what did you do?