View Full Version : I am newb
can someone tell me how to make a button to turn background music on and off?
i think i got the onClick part right, but what's the object name for background music?
-Pace
btw, cool forums.
inkedmn
10-07-2002, 10:00 PM
are you able to start the music playing? i'd be willing to guess that it's probably the same object...
if it's not too long, post your code here so we can have a peek...
<form>
<input type="button" value="click here" onClick="bgsound='music.mp3'">
</form>
that's what i have now. I really have no idea what to put in onClick=" "
nothing plays now, but before i had:
<body bgsound="music.mp3"> and it would play, but i want to have the option of turning it on or off.
-Pace
Halide
10-08-2002, 10:21 AM
oh, some javascript hmm
the onClick html tag contains the actual javascript, and I don't think you can start/stop it like that... unless you use the embedded sound player with the play/stop buttons... :D (btw, hi pace)
you will need to do this...
-----------------------------------------
<script language="javascript">
funtion music(){
// code to play music here;
}
</script>
<form>
<input type="button" value="click here" onClick="music()">
</form>
wow i should've been able to figure that out :rolleyes:
thanks :>
-Pace
fast reply :]
how i make clickable links on my sig?
-Pace
[u_rl]address in here[/_url]
take out the _ in each tag
Silver_Coder
01-22-2004, 07:13 PM
Wow I came in to help and I find Gish on top of things? Well maybe you could help me as well?
vBulletin® v3.7.0, Copyright ©2000-2009, Jelsoft Enterprises Ltd.