Results 1 to 6 of 6

Thread: How do I make random mp3 files play when page refreshes ?

  1. #1
    Join Date
    Aug 2006
    Posts
    17
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default How do I make random mp3 files play when page refreshes ?

    I have a much better understanding how it should work, but I can't seem to figure it out.

    the random text works great, but what about embeded mp3 files ? How do I get an mp3 at random to play upon page refresh. Just one mp3 per refresh.

  2. #2
    Join Date
    Jun 2006
    Posts
    182
    Thanks
    0
    Thanked 14 Times in 14 Posts

    Default

    Just print the entire embed tag like the quotes.

  3. #3
    Join Date
    Aug 2006
    Posts
    17
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    This is a sample embed from my web site. I can't get it to work in the script as a random sound.

    Can you show me how the tag should be slipped in. I've been trying and I can't figure it out.

    <EMBED SRC="http://www.selectivemusicinc.com/sound/machine01.wav"
    ONMOUSEOVER="TRUE" AUTOSTART=TRUE LOOP=FALSE HIDDEN=TRUE>

  4. #4
    Join Date
    Oct 2005
    Posts
    38
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I believe the rest of the true and false statements should have quotations around them aswell. And I'm not sure what you're trying to do with the mouseover statement.
    Btw this isn't Javascript, unless you were asking for the javascript code to make the page refresh aswell.

  5. #5
    Join Date
    Aug 2006
    Posts
    17
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I just figured it out....

    I needed to put \ infront of " in the embed so it could read it

  6. #6
    Join Date
    Aug 2006
    Posts
    17
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    The originaly script I was trying to make work was .js

    http://www.selectivemusicinc.com/bgmusic.js

    and I thought I had to make this list and use js to get it and make it play.

    I never figured that out. Someone told me I would have to use php and I got confused.

    But this works....

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •