Click to See Complete Forum and Search --> : make my browser "ding"


getho
08-31-2003, 11:44 PM
Howdy:
Just looking for feasability at the moment (not asking anyone to write my code for me!)
I'd like my browser to play me a wav file when it gets sent some info - I'm using a chat script and I want the browser to alert me when that window becomes active.
Is it possible? This would be something I'd run locally not on the website (ie I'd have the chat script in a window on my computer with custom script just for me - user of the site wouldn't ding in other words).

Getho

Khalid Ali
09-01-2003, 09:02 AM
yep..it sounds like yo should not have any problem playing a sound file in a window,however last part of your question is a bit conusing, me no understanding..:-)

BestZest
09-01-2003, 10:20 AM
Could you explain the last bit more clearly? Are you getting info sent from a website to your computer, or are you sending your self the info from another computer or something. Anyways, here is a little script that might work for you:

In the <script> tags:
function alertMe() {
document.getElementById("sound").src="ding.wav"
}

In the <body> tags:
<bgsound id="sound" />

This might work, I havn't tested it,

BestZest