Jump to content

Archived

This topic is now archived and is closed to further replies.

johnnyk

Background sound

Recommended Posts

What's the best way to embed a sound into a webpage so that it will work with most browsers? Also has to be something that doesn't give the Firefox plugin error.

Share this post


Link to post
Share on other sites
Well I'm not positive about the firefox plugin error, but this should work in all browsers:
[hr]
[pre]<embed src="Beethoven's Symphony No. 9 (Scherzo).wma" autostart="true" loop="true" width="500"
height="100">
</embed>
<noembed>
<bgsound src="Beethoven's Symphony No. 9 (Scherzo).wma" loop="infinite">
</noembed>[/pre]
[hr]
just use your sound file instead of that one.
the noembed tags are so that older versions of IE can use it, and it keeps newer versions of IE from reading it and the embeded one and getting an error.
Hope this helps

Share this post


Link to post
Share on other sites
oh ya and you can change the height and width to whatever size you need.
(making them both zero makes it Invisible)

Share this post


Link to post
Share on other sites
Many people are annoyed by background music. It's one of the most annoying things on the internet.

Share this post


Link to post
Share on other sites
I didn't think that FF would handle windows media files properly by default... but EMBED isn't a W3C tag, nor is BGSOUND -- OBJECT would be the right way to go.

Share this post


Link to post
Share on other sites
<embed> was developed by Netscape in the 90s as part of many proprietary elements during the browser wars between them and MicroSoft. It behaves buggy in Firefox but is supported by Internet Explorer.

That aside if you want to learn about what is called bounce rates put audio on your page and play it without asking the user. It is considered both rude and invasive. For the most part people expect for their browsing experience to be silent unless they are actively using a multimedia file. It was trendy for amateurs to put midi files into their pages and autoplay on load back in the mid 90s. It along with flash sites with obtrusive intros or annoying splash pages are not user oriented and will put off more people that they impress.

If you want people to be interested in the sound you have to offer I would suggest a prominent link in the middle of the page or in an obvious place to say, "Turn On Music" or some such.

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.