Jump to content

mp3 on a webpage


aniesh82

Recommended Posts

 

 

I want to put an mp3 on a webpage so people can listen to it.  I don't want it in the background playing automatically.  I would think a play button/slider thing would work.  What are my options?

 

Right now I have a hyperlink pointing to the file.  When you click on it, it will play, but I want something more professional.

Link to comment
https://forums.phpfreaks.com/topic/88499-mp3-on-a-webpage/
Share on other sites

right there isnt anything else loool :) you could have links to direct ppl to download flash if they can't load the mp3 right.

 

Otherwise i use

<object> and <embed> tags and php with links like

www.mysite.com/?play=3456

 

and then that 3456 number is the ID of the link (URL) on the database.

 

and have something like this.

 

 

<object src="$ID">

 

 

dont know if all this makes sense but you know it has alot of coding in it so you know....

 

 

PS hope it helps

Link to comment
https://forums.phpfreaks.com/topic/88499-mp3-on-a-webpage/#findComment-453088
Share on other sites

Your options:

 

  • Embed a flash player to play the music file (works in just about every browser nowadays)
  • Embed a windows media player plugin on the page and play the MP3 file (not working on linux or mac)
  • Direct the users to a link which they can load into their own media player

Link to comment
https://forums.phpfreaks.com/topic/88499-mp3-on-a-webpage/#findComment-453092
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.