WordPress.org

Ready to get started?Download WordPress

Forums

Attn Smart People: please help with code for music on blog! (13 posts)

  1. beccalouise
    Member
    Posted 8 years ago #

    I saw a member post this code for music on a blog

    <!-- Begin Music Section -->
    <script language="javascript">
    function BeginMusic(){
    if(document.MusicForm.snd.value == 'Music on')
    {
    document.all.music.src='http://www.sharemation.com/parsa1976/Zebigniew%20Preisner%20-%20Dekalog%20VIII%20-%203.WMA';
    document.MusicForm.snd.value = 'Music off';
    }
    else
    {
    document.all.music.src='';
    document.MusicForm.snd.value = 'Music on';
    }
    }
    </script>
    <center><form name="MusicForm">
    <input name="snd" type="button" value="Music on" OnClick="BeginMusic()">
    </form></center>
    <bgsound id=music loop=-1 autostart="true" >
    <!-- End Music Section -->

    But I don't know what to fill in with in the code to make it work. Can someone please enlighten me on this, as well as where I can find the file name for the music on my computer. I am really clueless!!

  2. ladydelaluna
    Member
    Posted 8 years ago #

    as mentioned in that other thread, having music start by default on your site like this is considered bad form. i'd have to pretty much bet on the fact that a minimum of 99% of your viewers will HATE it... the other 1% won't have speakers so it won't affect them.

    just think - if you were using your computer to play the music YOU like, and you went to a site that forced music to overlap your favorite tune... you too would hate it, right?

  3. Mark (podz)
    Support Maven
    Posted 8 years ago #

    Solutions ..... she's after solutions....

  4. ladydelaluna
    Member
    Posted 8 years ago #

    there are... alternative ones listed on that other thread that she was already on...
    http://wordpress.org/support/topic/28835

  5. Mark (podz)
    Support Maven
    Posted 8 years ago #

    This line:
    document.all.music.src='http://www.sharemation.com/parsa1976/Zebigniew%20Preisner%20-%20Dekalog%20VIII%20-%203.WMA';

    is where the music file seems to be being called.
    Put the full url to your sound file there?

    The whole chunk of js would probably go in the <head> section of the page.

  6. Mark (podz)
    Support Maven
    Posted 8 years ago #

    I meant that here is not the place to express opinions about what someone wants to do on their webpage.
    People post here for assistance - not lectures.

  7. ladydelaluna
    Member
    Posted 8 years ago #

    *sigh*

  8. lhk
    Member
    Posted 8 years ago #

    Hi,

    I can understand Ladydelaluna's reaction. I backpedal QUICKLY out of ANY site having music. It's instinctive and there's really no better way to ensure, that no one reads a site than doing this to people.

    So, at least try to ensure that the music is OFF when people enter, and that it can be turned on (and OFF again) only by decided will and action of the visitor.

  9. Mark (podz)
    Support Maven
    Posted 8 years ago #

    Right.
    ANSWERS ONLY below. Just answers. No opinions.

  10. Mark (podz)
    Support Maven
    Posted 8 years ago #

    http://musicplayer.sourceforge.net/
    is not too bad.
    It's a couple of URL's to edit and you can use more music, stream etc. And it's free :)

  11. Dgold
    Member
    Posted 8 years ago #

    You might want to try the embeddable player from Radio Blog
    http://www.radioblogclub.com/

    By the way, MySpace has millions of bloggers & readers, and all of them play music right when you launch the page. It is becoming more common on personal blogs & mp3 blogs.

    Plus, it is ordinary for Band's websites to play music automatically, and WordPress is great for making a band website.

  12. flakkito
    Member
    Posted 8 years ago #

    This player is for me the simplest ever while retaining the most options for customizing and can be called to open in a popup or embedded in a page. It can be set to play automatically or not.

    http://www.wimpyplayer.com/

  13. Pizdin Dim
    Member
    Posted 8 years ago #

    "ANSWERS ONLY below. Just answers. No opinions."

    How about an opinion disguised as a question? Don't you find it annoying when someone starts a thread, gets people engaged in the discussion and then just starts another identical one?

    Why do people do that?

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags