Left Click anywhere on a blank part of the page for a popup menu!

Rated G There are 2 (invisible) frames at this site. If you see any frames
you are probably stuck in someone else's. FIX IT HERE

colorbar.gif

Eddie 2Dogs
Website Primer
Section 5. Sounds, to Embed or not to Embed
colorbar.gif

A Controversy

When it comes to multimedia embedding on websites I take a cautious approach, and these are the reasons why:

  • Copyright of the sound must be taken into account, whether midi, wav, mpeg, or realaudio encoded music. You can bet if the sound is not homemade my yourself it belongs to someone else.
  • Automatic playing of most sound or video files takes a huge chunk of memory and cpu time, and will slow your site down to a crawl.
  • The only reason to embed sound is to wow your visitor, and what you like for sounds, especially music styles, may directly influence them to stay or to leave.
  • If pre-loaded, is there an option (in an obvious place) to turn it off? If not, the only course is to exit the site.

    Browser Compatibility

    Netscape and Internet Explorer use different html tags. If you are not concerned and want only to use the Netscape or MSIE statement then copy the appropriate one over. All people using "the other browser" will not hear a sound.
    The width and height statements are for the console containing the play and stop controls. In this case, because the sound is only a couple of seconds long they are turned off and the sound is only played once (loop is turned off).

    For Netscape use the following:

    
    <EMBED SRC="yoursoundfile.wav" AUTOSTART=TRUE LOOP=1 WIDTH=0
    HEIGHT=0></EMBED>
    For MSIE use the following:
    
    <bgsound src="yoursoundfile.wav" loop=1>
    
    
    The following is a script which will check the browser being used and it will load the appropriate tags (statement), forcing compatibility. It is done using Javascript and the logical arguments (if, and, or, equals.). However, it is now giving problems in our newer browsers and or plugins......but try it first...
    
    <SCRIPT LANGUAGE="JavaScript"> 
    
    <!--//
    
    if (navigator.appName == "Netscape") { 
    
         document.write('<EMBED SRC="yoursoundfile.wav" AUTOSTART=TRUE 
    LOOP=1 WIDTH=0 HEIGHT=0></EMBED>') } else { if (navigator.appName == "Microsoft Internet Explorer")
    document.write('<BGSOUND SRC="yoursoundfile.wav" LOOP="1">') } //--> </SCRIPT>
    The previous will also work for midi sound files. Be careful of the file's size, anything over 20Kbytes will slow things down, especially if looping the sound, playing it infinitely over and over ad infinitum. Please don't do that. For those who are having trouble with the javascript do the following...copy both the MSIE and Netscape codes over as one entity....the one which doesn't work will just be ignored, and to blazes with the javascript version.
    <bgsound src="yoursoundfile.wav" height=54 width=200 autostart=true loop=1>
    <EMBED SRC="yoursoundfile.wav" autostart=true width=200 height=54 loop=0></EMBED>
    
    You can play with the height and width statements to size your console...

    Real Audio

    The greatest asset of Real Audio is that the sound is compressed and can be made to "stream". That means it can play while it is being downloaded without having to wait for the complete file to be cached.
    Sound files with the extensions .ram, .ra, .rm are all RealAudio. Please do not embed these file types. The computer will be too busy streaming or downloading to finish loading your site.
    Usually this format is used to play whole songs, or sound bytes from speeches, and is used mostly by musicians who want to give access of their music over the web. MP3 format sound files do the same, and are considered even better sounding, but are also much larger, usually 2 to 5 Mbytes in size and are prohibitive when being used at a website. They are usually for download only and the majority are ripped off CD's open to prosecution for copyright infringement.
    My site contains RealAudio of the music of the Bizzarre Kazoobees, the Croakers, and my own music and are copyright by these entities and used by permission.
    To get the audio to "stream" commonly called an "HTTP Livestream" one must build a ram file. This is a text file with the extension .ram. The only text it contains is the complete url of the rm or ra file. Here is a working example:

    This goes on your page which calls the text file, the text file in turn calls the audio file to stream...(loads the RealAudio application)

    
    <A HREF="blues.ram">"Croaker Blues"</A>
    
    

    text file below, is saved as blues.ram

    http://www.fortunecity.com/millenium/fairview/50/blues.rm

    One does exactly the same for streaming mp3 files...save the actual sound file with the .mp3 extension, then build a m3u file in exactly the same manner as a ram file but save it with the .m3u extension. Careful with mp3's..they are huge files, and for streaming you should make a copy of the high-grade file using 24 bit compression. This lower quality sound is known as lo-fi and streams much better.

    Be careful where you upload your RA or MP3 files, as not all servers are configured to stream these files.


    The Rules Backgrounds Music Java Compatibility
    Main Site Index Ratings System Icons

    Copyright © 1999 Ed Ladeur,


    Eddie Dog2
    Box 1353
    150 Mile House, BC
    Canada, V0K 2G0
    [email protected]