WebBuilder101 - Making the web happen!
Need Web Dev software? Here is the place to
Flash Point
Embedded Sound


Have you ever seen web pages that play music while displayed in your browser? If so, have you ever asked yourself how it's done? Well, let's find out what makes such web pages tick.

There are many ways you can add sound to web pages, for instance, you can use scripts or simple HTML to embed sounds on them, or you could use helper applications such as Real Player to accomplish the same effect. Let's take a look at simple way to add/embed sound on a web page.

Below is the HTML you need to copy in the BODY of your document.

<EMBED SRC="your-sound-file.mid" AUTOSTART=FALSE LOOP=7 WIDTH=150 HEIGHT=50 ALIGN="CENTER"></EMBED>

EMBED alerts the browser that it needs to load a plug-in to play the sound/music.

AUTOSTART allows you to decide whether you want the sound to play automatically or not (in this case the viewer needs to start the music). If you want the sound/music to start automatically you have to set the following to AUTOSTART=TRUE.

LOOP if set to TRUE will play the sound/music forever, if set to FALSE, the sound will only play once. In this case, LOOP is set to 7 - which means that the sound/music will play seven times and then stop.

WIDTH/HEIGHT/ALIGN allows you to control the plug-in's control panel size (viewer will need this control panel to start the sound/music if AUTOSTART is set to FALSE).

There are some disadvantages to embedding sound on web pages with the command above, for instance, one has to wait for the entire sound file (MIDI, WAV) to download before the sound can be heard, also note that not all Browsers may recognize such command - the command above will work on Netscape only, to make it work with IE you need to add the following command: BGSOUND="your-sound-file.wav".

.

 

More Resources
What is HTML?
Learn the code
HTML Editors
HTML Tutorial
A quick guide to having a web presence
Dynamic Web Sites
Browser Options
Browser Upgrade

Suggested Reading

Beginning Active Server Pages 3.0
JavaScript Bible
Red Hat Linux
Dreamweaver 3.0
HTML Bible



Download WB101 Wallpaper
• Web Builder 101 Wallpaper Get it!.
• Find out how to create your own Wallpaper Teach me!.
Sign up for our Newsletters
• Web Building Sign me Up!.
• Net Alert! Sign me Up!.
Need Help?
• Contact Support Click here.
• E-mail the Webmaster Click Here.
• Search Tips Click Here.

Webbuilder101.com © 1998 - 2003 Copyright and Terms of Use
Send mail to: webmaster@webbuilder101.com

» About » Support

» FAQ » What's New » MyLog

Web Builder 101 Web Builder 101 - Making the Web Happen Web Builder 101 - Making the Web Happen
.