...

View Full Version : Not getting sound alert when the page is minimized



pkp_it
12-21-2007, 07:19 AM
Hi All,

Please help me to get the right code:

There are two web pages, say page1 on PC1 and page2 on other PC2.

From page1, I request for rate from page2.
Current Behaviuor:
"When I click the button On page1 to get the request from page2, we get the sound alert on PC2 only when page2 is open."

Expected Behaviour:
"When I click the button On page1 to get the request from page2, there should be sound alert on PC2 whether the page2 is open or minimized to taskbar."

Javascript Code which I implemented:

function audioAlert() {
var audioFrame = window.document.audioFrame;
if (audioFrame) {
audioFrame.document.write("<bgsound src='" + this.audioAlertUrlHome + userPref.audioAlertFile + "' loop=1>");
audioFrame.document.close();
}
}

The error, most probably, is with the line:
audioFrame.document.write("<bgsound src='" + this.audioAlertUrlHome + userPref.audioAlertFile + "' loop=1>");
and particularly with the write() method.
So Please tell me the right code/alternative code/sample code.


Regards,
Kumar



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum