Dashboard > SmugMug > Home > Customization > How To Add Music
Log In   View a printable version of the current page.
SmugMug
How To Add Music
Added by Andy Williams , last edited by Andy Williams on Dec 25, 2008  (view change)
Labels: 

Music is something many folks want to add to their websites. Some folks absolutely hate music on websites, others don't mind it. Used carefully, it can be fine.  Start with the music OFF... but if you don't, be sure to have a button that will allow it to be turned off.

You'll want to use music that you have rights to, so be careful about violating any copyrights.

 A great source for music to embed them on your page is Magnatune. Just go to their page, pick any genre you like and look for an artist or an album. When viewing an album page, you should see a link "embed this album on your own page". Click on it to get the code that you have to embed into your site. Make sure that you select to have the music off by default so that your visitor can choose to turn it on if he wants to.

Here's a sample of the small player embedded into a gallery description.

You can also host your music on another site (even a free site, like Google Sites) and then play it on your SmugMug site. Here is some example code.

<embed src="http://www.yourstorageplace.com/yourmusicfile.mp3" width="70" height="18" autostart="false" loop="true">

IMPORTANT!  If you put your music in your footer section, be SURE to wrap it in a div.  Like this:

<div id ="my_music"> <embed src="http://www.yourstorageplace.com/yourmusicfile.mp3" width="70" height="18" autostart="false" loop="true"> </div>

And then use THIS CSS in your CSS Box to make it work only on your homepage, or a gallery page.

#my_music {display: none;}
.homepage #my_music {display: block;}

or
.gallery_XXXXXX #my_music {display: block;}

If you want to discuss music on your website, make a post on Dgrin's Customizing Forum.

References

Notes: remember, you must have the right to use the music on your website, so be careful.

I tried and tried to make this code work, and I think I found the problem:
<div ="my_music">
SHOULD BE
<div id="my_music">

Posted by Anonymous at Apr 29, 2008 23:59 | Reply To This

How do you get rights for songs?

Posted by Anonymous at May 07, 2008 08:47 | Reply To This

Well, I am not new to edit web-pages, but pasting the code from Magnatune in my Gallery description is not working. In fact the explanation here "How to add music" tell all about where to get the music from, but not a word about how to add music...like where to past the code, and tips in case like mine when is not working.

Posted by Anonymous at Jun 11, 2008 00:13 | Reply To This

<a href="http://runtone.com/">Rintone ringtone</a>
<a href="http://runtone.com/">Rintone ringtone</a>

Posted by Anonymous at Aug 06, 2008 09:41 | Reply To This

[url="http://runtone.com"]ringtone[/url]

Posted by Anonymous at Aug 06, 2008 09:42 | Reply To This

If I purchased a song, do I have rights to be able to play it on my website? Is there a place where I can read about copyright issues regarding music?

Thanks

Posted by Anonymous at Sep 04, 2008 22:31 | Reply To This

We cannot give advice on whether your specific song purchase gave you rights to post the song on your site.   I would recommend checking with the site you purchased from.  They should have a license or other document describing what you can do with the song you purchased.  In most cases, your purchase is for personal use and not public performance so make sure your purchase includes allowing use on your website.

Hi -

Using the approach described here, will the music remain on while the user stays on the site... until they click the "OFF" button?

If the user navigates to another page on your site, will the music re-start from the beginning.... or continue smoothly?

Thanks,

Tom K. 

Posted by Anonymous at Sep 09, 2008 13:53 | Reply To This

I have  finally gotten my music (and slide show) to work on my site here: http://russmacdonald.smugmug.com/

Here's what I did:

Copied the code from Magnatune into my Footer.

Then, I added this in front of it:

 <div id="my_music"

and this after it:

</div>

These two Div tags enclose the code and name it "my_music".

At this point the music will play on all pages of your site. Unfortunately, the music will always restart when you go to a new page, and I did not want that.

So, I entered the following code in my CSS to make the music only play on the home page.

\#my_music {display: none;}
.homepage #my_music {display: block;}

 

Unfortunately, I had a slide show on my first page, and I had used the trick of duplicating my home page to move my galleries off the first page, so I had to add one more line to stop the music from playing on you galleries page:

.galleries #my_music {display:none;}

Now it works right.


Posted by Anonymous at Oct 17, 2008 22:03 | Reply To This

with the Magnatude site... how do you pick just ONE song like the example above?  Everything I see you can only pick an entire album!  Any ideas?

Posted by Anonymous at Nov 24, 2008 16:12 | Reply To This

There's a typo in the initial instructions.  It says:

Unknown macro: {dispaly}
and should be
Unknown macro: {display}

Posted by Anonymous at Dec 03, 2008 22:18 | Reply To This
Powered by Atlassian Confluence 2.7.1, the Enterprise Wiki. Bug/feature request - Atlassian news - Contact administrators