473,385 Members | 2,069 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Object tag for music file in XHTML

I want to add background music to my xhtml page. I'm using the object tag as seen below and it works fine, except that I want to add more than one song to the list.

Can someone tell me how to add more than one song to the a href?

<object type="audio/wma" data="music/fantasy files">
<param name="src" value="media player.wma" />
<param name="autoplay" value="true" />
<param name="autoStart" value="true" />
<a href="The_Wolf.wma">
<img src="images/music_icon.jpg" alt="Background Music" height="40" width="40" /></a><br /><br />

</object>

P.S. I would use Flash but I have no idea how to get it to work with flash. Tried many options via googling it but I think I just don't have the programming expertise to get it to work..
Feb 27 '09 #1
1 4804
Dwagar
6
Only way I know this may be possible is using javascript and setup some timers if you know how long each song is, but in this case it is a lot easier using a flash player.

If you need to give the object an ID like ID="VIDEO" and the javascript code will look like so for playing another song.

<script>
setTimeout('document.getElementById(\'VIDEO\').URL =\'filename\',18000);
</script>

The 18 will be 3 minutes if the first default song is 3 minutes long. Flash will be more reliable, I never tried this way but may work.
Feb 28 '09 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

15
by: Ville Vainio | last post by:
Pythonic Nirvana - towards a true Object Oriented Environment ============================================================= IPython (by Francois Pinard) recently (next release - changes are...
12
by: Marian Aldenhövel | last post by:
Hi, I am trying to make pygame play music on windows. This simple program: import pygame,time pygame.init() print "Mixer settings", pygame.mixer.get_init() print "Mixer channels",...
20
by: gallery | last post by:
Our client insists on having a music loop playing as the visitor travels throughout his new HTML website. We will not be doing this in frames and I would prefer not to have the home page spawn...
7
by: mike p. | last post by:
I have a docbook xml file, and am using standard docbook 1.61.3 xsl stylesheets to do xhtml transform. Transform works fine when using MSXML. When I try to do the following using asp.net 1.1: ...
2
by: rsd | last post by:
Hi, I'm trying get Samsung YH-920 mp3 player to work with Debian GNU/Linux. To do that I need to run http://www.paul.sladen.org/toys/samsung-yh-925/yh-925-db-0.1.py script, the idea behind the...
4
by: C.W.Holeman II | last post by:
I am using Firefox 2.0.0.3 on MSWindows. I have an XML file http://emle.sourceforge.net/emle020000/testb.xml which invokes an XSLT file http://emle.sourceforge.net/emle020000/testb.xsl <?xml...
2
by: FlashForumKB | last post by:
Here is a chance for you to make my developers look bad. I have hired these guys to development my website which, in part, has music demos available to my users. These demos must include the...
2
pbmods
by: pbmods | last post by:
At the request from MacMan247, I am hereby posting the 'how I did it' to get the music from ShadowWraith. Here's what I did. Turns out that the music is stored in MOD format inside the...
2
by: Jinx08 | last post by:
I am probably an itermediate user when it comes to flash however I am at a loss with this problem. I have posted numerous flash files to the internet and never had this problem however the key there...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.