Jump to content






Embed Music in your Blog

Posted by jinryuichi, 28 April 2007 · 470 views

SeraphK just gave me a good idea to add another element to the blog - Music.

It's been a LONG time since I've done this, but it's a cool thing to have. It invites your readers to linger around longer and read your blog. Or lures your readers to come back to your blog just for the music. Here's some tips on how you can embed music to your blog.


Method 1: The traditional way.
<a href="yourmusic.extension">Click here to play music </a>
Click to play.... Nuff said.




Method 2: Embed and play automatically
<embed src="yourmusic.extension"> 
<noembed> 
<bgsound src="yourmusic.extension"> 
</noembed>

Now, think carefully before you do this. This code will play the music automatically once the page loads. Some people gets annoyed because of this, it's ok for those who are at home. Nobody wants have the speakers blasting music suddenly when you're in school or at work.... it alerts everyone around you and tells them that you are surfing around instead of doing work. :P ... which brings us to the next method.





Method 3a: Embed music with start/stop control - all platforms (with Apple Plugin)
<embed src="yourmusic.extension" width="150" height="70" type="audio/mpeg" autostart="false" loop="false" bgcolor="white">
This method gives the visitor a "start/stop" button. However it requires that you have the Apple Plugin if you don't have it installed in your PC already.


Method 3b: Embed music with start/stop control - Windows only
<object classid="clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95"  width="180" height="46" >
<param name="FileName" value="filename.extension">
	<embed  type="application/x-mplayer2" src= "yourmusic.extension" autostart="false" loop="false" height="180" width="46">
<param name="autoplay" value="false">
<param name="controller" value="true">
</object>
This method calls up the Microsoft Media Player to play your music on the browser. However, this method is only for visitors who are browsing with a Windows PC. Linux users can't see a thing.


NOTE: Method 3a and 3b will not play your music automatically. Because of this setting:
autostart="false"



Method 4: Use Flash
This one works for everything that has Flash installed. That's 90% of all web surfers. You can use 3rd party standalone players like Radio.Blog.Club or Last.FM, and you don't need to have your own webspace to store your music and player.
If you want to know which one suits you best, this may be rough guide.
As for me I used XSPF Web Music Player, as you can see on the sidebar. This one's useful only if you have your own webspace to upload your music and the Flash Player.
The good thing about this method is that you have a playlist to play a few songs instead of just one.


Complicated? Well, it's not that bad once you get the hang of it. And well worth the time if you can get it to work. Drop me a message if you need any help.

Have fun!




As a reader I prefer method 1.
The easiest way of course...... :drool:
Thanks for all the help Jinryuichi, unfortunately I'm busy with work right now, so, probably when I get home tonight, I'll start playing around with it. Most likely I'll go the flash route, don't think I'll even bother with method 1 :drool:
How'd you get your own webspace??

Thanks again,
Seraph~

Thanks for all the help Jinryuichi, unfortunately I'm busy with work right now, so, probably when I get home tonight, I'll start playing around with it. Most likely I'll go the flash route, don't think I'll even bother with method 1 :drool:
How'd you get your own webspace??

Thanks again,
Seraph~


No probs... ^^;

As for the webspace, well just sign up for one.
OR you can use the free ones like Ripway and FileAve.
Quick question, haven't played much with the music aside from FineTunes, and poking around the other sites. But, is it possible to make a separate player for each entry using the traditional method?? I'll still play around with the other things, but was wondering if it is possible?? =D

Thanks again for the help~ m(_ _)m
Seraph~

Mame! Playa



Like them songs? Buy it!



Check out WWW FAQs: How do I embed sound and music in a page? on Boutell.Com's web site.

About This Mini Blog

Welcome to Mame!,
a free-talk and pic-talk mini blog.

Also visit my Hello! Project blog ->

H!P - Hello Non Pro Hour.

Thanks for stopping by~~! :w00t:



April 2024

M T W T F S S
1234567
891011121314
151617 18 192021
22232425262728
2930