There is a feature of the Chatroom module that is not working. There is a 'Alert me if new messages are received.' checkbox but no sound plays even when it is checked.
The admin user sees the following error message:
soundManager.initComplete(): calling soundManager.onerror()
-- SoundManager 2 failed to load (security/load error) --
soundManager.disable(): Disabling all functions - future calls will return false.
soundManager: Failed to initialise.
soundManager: No Flash response within reasonable time after document load.
Possible causes: Flash version under 8, no support, or Flash security denying JS-Flash communication.
soundManager: Getting impatient, still waiting for Flash.. ;)
soundManager.beginDelayedInit(): Document loaded
soundManager._initMovie(): Waiting for ExternalInterface call from Flash..
soundManager._initMovie(): Got EMBED element (created via JS)
soundManager._createMovie(): Trying to load ./soundmanager2.swf
-- SoundManager 2 V2.76a.20080808 (AS2/Flash 8) --
This is drupal 6, and ChatRoom 1.0-beta2
We suspect there could be some kind of js conflict, but are having trouble chasing it down. Has anyone else run into this problem? We are using the admin menu module which has been known to cause some other js weirdness in our experience, though not in a while.
Comments
Comment #1
marioboy90 CreditAttribution: marioboy90 commentedI have the same problem! Any advice?
Comment #2
marioboy90 CreditAttribution: marioboy90 commentedI have the same problem. Any advice?
Comment #3
SuperContraXTC CreditAttribution: SuperContraXTC commentedPlease help, I am having same issue
Comment #4
SuperContraXTC CreditAttribution: SuperContraXTC commentedPlease help, I am having same issue,
Other related
http://drupal.org/node/359750
Comment #5
paku CreditAttribution: paku commentedThe same here ...
Comment #6
Curugon CreditAttribution: Curugon commentedSame here! At the very least, I need to figure out how to stop the debug code from showing up to users.
Comment #7
pkej CreditAttribution: pkej commentedAt #6 I did a quick search and found that soundmanager2.js has a line (line number 25) saying
Using that I identified all the other instances of self._writeDebug and I guess commenting out all of them is the quick and dirty way to get rid of the messages. I guess there is a way of turning debug on/off the line (line number 16with:
seems a very likely candidate; you could try to just comment out that line first, and see. I'm sure it is there just for the beta release and is supposed to be turned off at a later time.
Comment #8
adam_b CreditAttribution: adam_b commentedsubscribing & updating to beta3
Comment #9
Anonymous (not verified) CreditAttribution: Anonymous commentedplease update to beta4 - it won't fix the sound issue, but it has a few more bug fixes.
Comment #10
adam_b CreditAttribution: adam_b commentedjust did, thanks :)
Comment #11
Anonymous (not verified) CreditAttribution: Anonymous commentedi've committed a fix to turn off the debug, so update to the latest CVS to get that fix. i don't know anything about the soundManager code, so i'd love some help from anyone who was around when that got committed.
Comment #12
Anonymous (not verified) CreditAttribution: Anonymous commentedi'm going to port the sound stuff to use a jquery plugin, and just junk the old, broken stuff.
any volunteers to help with this?
Comment #13
pmaguniaI'm not sure this is the right place to post this info, but on my chatroom module I didnt see any code for sound so I tried tweaking it a bit. The version of chat room I am using is 2.7
After installing soundmanagerv295b-20100323, I successfully got sound with new messages. Sound Manager 2 is very picky about directories so I installed everything in the chat room directory. I added the following code to the end of the soundmanager2.js file:
In chatroom.module I added the following line around line 884 around in the vicinity of the other add_js command:
drupal_add_js(drupal_get_path('module', 'chatroom') . '/script/soundmanager2.js');
Note: sound manager directory contents, src, swf, demo, and script are located in the chatroom directory.
Also I replaced some code in chatroom.js with the added soundmanager lines:
This should give you sound with new messages when you click 'submit' not enter. Make sure you have sound_1.mp3 at the appropriate above directory and you include your own url. Also I think you can get rid of the initialization message by adding the code to the nodebug version of soundmanager2.js located in the scripts directory.
I tested this with IE7, IE8 and FF 3 on windows and mac and it works ok. To get a sound when you receive messages may take some additional tweaking.
I hope you are able to duplicate my success. Please let me know if any clarification is needed. Thanks
Comment #14
Anonymous (not verified) CreditAttribution: Anonymous commented