62 users online (1 members and 61 guests)  


Page 1 of 2 1 2 Last
  Results 1 to 15 of 21

Related

  1. Playing video on my site    Forum: HTML Forum
    Replies: 3
  2. Music Files    Forum: HTML Forum
    Replies: 2
  3. Playing a music file    Forum: HTML Forum
    Replies: 0
  4. Playing with pixels in positioning    Forum: CSS Forum
    Replies: 1
  5. Playing music files on web pages    Forum: HTML Forum
    Replies: 2
  1. #1
    Wendy's Avatar
    New User

    Status
    Offline
    Join Date
    Apr 2001
    Posts
    9

    Question Playing music files on web pages

    I want to put a MIDI file on my web page and have it automatically played, but I can't find the html code to do that. Could someone please help?

  2. #2
    Enigma's Avatar
    Senior Member

    Status
    Offline
    Join Date
    Nov 2000
    Posts
    426

    Post

    <embed src="titleofmidi.mid" width=145 height=55 autostart=true
    loop=true> according to addagirl, Sound Mistress.


  3. #3
    HTML's Avatar
    Administrator

    Status
    Offline
    Join Date
    Aug 2000
    Posts
    3,445

    Follow HTML On Twitter Add HTML on Facebook Add HTML on Google+ Add HTML on Linkedin Visit HTML's Youtube Channel

    Post

    Hi Wendy,
    welcome to the forums

    Dave
    Last edited by HTML; 09-10-2003 at 06:04 PM.

  4. #4
    webmistress's Avatar
    Junior Member

    Status
    Offline
    Join Date
    Apr 2001
    Posts
    48

    Wink

    I like to use:
    <embed src="song.mid" hidden="false" autostart="true" loop="-1" controls="smallconsole" height="25" width="100"></embed><strong> Click on the controls to turn off the music.</strong>


    to remind folks that they have control over whether they want to listen to my choice of music. If you don't want looping (midi plays one time through) loop="0". If you don't want a console (and risk people clicking immediately away cuz they don't want the music) hidden="true".

    HTH,


  5. #5
    Wendy's Avatar
    New User

    Status
    Offline
    Join Date
    Apr 2001
    Posts
    9

    Post

    Thanks guys. I think my player is messed up, because I can't play it when I tried it out. Check it out at:
    http://www.geocities.com/gwyn89/music.html

    Could someone tell me what's wrong?

  6. #6
    HTML's Avatar
    Administrator

    Status
    Offline
    Join Date
    Aug 2000
    Posts
    3,445

    Follow HTML On Twitter Add HTML on Facebook Add HTML on Google+ Add HTML on Linkedin Visit HTML's Youtube Channel

    Post

    It looks as if you have the code twice and they each intermingle. I is calling for a .ram file which is probably not supported on geocities.

    Dave

  7. #7
    QuietDean's Avatar
    Administrator

    Status
    Offline
    Join Date
    Oct 2000
    Location
    Bournemouth, UK
    Posts
    2,662

    Post

    Had a quick look. Player does not seem to have anything to play. is the *.mid file in the same directory as the page? I s the filename correct?

    ------------------
    QuietDean-

  8. #8
    Wendy's Avatar
    New User

    Status
    Offline
    Join Date
    Apr 2001
    Posts
    9

    Post

    Yes, the fact is, everything was correct. I'm totally sure. But it just doesn't work. I asked a friend and he said this should work:

    <BGSOUND = "URL of your midi" LOOP = -1>

    That's where I got a little confused. Just what is embed for and what is bgsound for? I didn't try the bgsound idea yet

  9. #9
    QuietDean's Avatar
    Administrator

    Status
    Offline
    Join Date
    Oct 2000
    Location
    Bournemouth, UK
    Posts
    2,662

    Post

    BGSOUND only works in Internet Explorer, to the best of my knowledge.

    I tell ya, I will have 'Only works in Internet Explorer' on my gravestone...

    ------------------
    QuietDean-

  10. #10
    QuietDean's Avatar
    Administrator

    Status
    Offline
    Join Date
    Oct 2000
    Location
    Bournemouth, UK
    Posts
    2,662

    Post

    Also, I copied the exact code form your source, and tried it at home. It works.

    So maybe Something to do with GeoCities? Do they let you play *.mid files?

    maybe your filename it Btit.mid or BTIT.mid.

    ------------------
    QuietDean-

  11. #11
    HTML's Avatar
    Administrator

    Status
    Offline
    Join Date
    Aug 2000
    Posts
    3,445

    Follow HTML On Twitter Add HTML on Facebook Add HTML on Google+ Add HTML on Linkedin Visit HTML's Youtube Channel

    Post

    try this code:

    <EMBED SRC="btit.mid" LOOP="true" HIDDEN="false" AUTOSTART="TRUE">
    <NOEMBED>
    <BGSOUND SRC="btit.mid">
    </NOEMBED>

    This should work in both NS and explorer

    Dave

    [This message has been edited by Dave (edited 04-22-2001).]

  12. #12
    Wendy's Avatar
    New User

    Status
    Offline
    Join Date
    Apr 2001
    Posts
    9

    Post

    Dean may be right... about the geocities thing. I'll try the codes on another site. Thanks guys!

  13. #13
    QuietDean's Avatar
    Administrator

    Status
    Offline
    Join Date
    Oct 2000
    Location
    Bournemouth, UK
    Posts
    2,662

    Post

    Let us know how you get on, Wendy.

    ------------------
    QuietDean-

  14. #14
    Wendy's Avatar
    New User

    Status
    Offline
    Join Date
    Apr 2001
    Posts
    9

    Post

    Thank you, I tried it out at Tripod.com and it worked just well at http://gwyn89.tripod.com/

    I might move my site there. Geocities must have a problem.

    What does the embed tag, bgsound and no embed tag mean?

  15. #15
    QuietDean's Avatar
    Administrator

    Status
    Offline
    Join Date
    Oct 2000
    Location
    Bournemouth, UK
    Posts
    2,662

    Talking

    Glad you got it working!

    The EMBED tage is a generic Netscape tag that does literally what it says. It embeds media files into a webpage, like music, video, Flash files

    The EMBED tag is not supported by Internet EXplorer. But the NOEMBED is.

    The trick dave used basically means -

    Okay Netscape, play this song please. But if thats you Internet Explorer, then please use BGSOUND instead. Cheers, browsers.

    As EMBED is Netscape, and BGSOUND is Internet Explorer, then the code works in both. It's a good way to code.

    ------------------
    QuietDean-



Page 1 of 2 1 2 Last

Tags for this Thread