14 March 2005, 14:15 UTC#1
I've got a webpage where music plays straight away as the page loads up. This can get annoying over a period of time. Does anyone know how to implement an on/off button on the page in html.
any help would be appreciated.
cheers.
nico.
14 March 2005, 14:15 UTC#2
autoplay=false
14 March 2005, 14:27 UTC#3
do I attach that code to a button?
14 March 2005, 15:05 UTC#4
QUOTE (Nico @ Mar 14 2005, 02:27 PM) do I attach that code to a button?
Nope, in the source code where you have embedded the media file, for example, open up your html file in notepad, you will see something that says embed=bla whatever ... then autoplay=true change autoplay=true to autoplay=false, if you have it so the player isn't visible, you can make it visible by replacing the current code with:
CODE <EMBED SRC=http://your_file.extension AUTOSTART=true WIDTH=144 HEIGHT=60 LOOP=1>
That code will automatically start the player on page load, but display the media player controls for it, it will also repeat itself unless clicked off.
To make it not replay use the following:
CODE <EMBED SRC=http://your_file.extension AUTOSTART=true WIDTH=144 HEIGHT=60 LOOP=0>
To make it replay but not start automatically use the following:
CODE <EMBED SRC=http://your_file.extension AUTOSTART=false WIDTH=144 HEIGHT=60 LOOP=1>
14 March 2005, 15:30 UTC#5
Thanks gazaa, al give it a try
14 March 2005, 17:55 UTC#6
gazaa = sound