I wondering how are sound alerts used in the chat.

In the "hacking.txt" file it says "Chatroom sounds should use a jquery plugin."

Under chat room settings and "Chat alerts" there is several chat alert check boxes, like "Enable chat alerts", but for the "Use custom sounds for chat alerts" there is nothing (that I can see) how this even give any function.

So my question is: How can I enable sound alerts (for new messages in the chat)?

Comments

inky@inky3d.com’s picture

I'd also like to know more about adding sounds.

Any progress on this?

geerlingguy’s picture

The question is - are there any sounds at all? It looks like nothing implements sound at all yet, which makes the last option seem misleading :(

Shane Birley’s picture

Category: support » feature

Marking this as a feature request as it appears no code has yet been written. Please correct if I am wrong.

Paolo61’s picture

Also for me there are no alerts sound at all. J.ve istalled jquery and jquery plugin but with no results !

jsgammato’s picture

I've got no sound alert, and I don't see any visual alert either. What should I be looking for?

pmagunia’s picture

If anyone sends a message a sound is played. Currently a limitation is the same sound is played if a message is sent or received, but it does work.

I installed soundmanager2 (http://drupal.org/project/soundmanager2) which is a Drupal project and jazzed up the chatroom.js files.

soundManager.play('new_msg', 'http://www.example.com/sites/all/modules/chatroom/sounds/sound_1.mp3');

You need to replace the url in the code above with a url to your sound file. I think you can use the sound file on my site as it is copy left licensed.

It is placed in between if (newMessage) {

and Drupal.chatroom.scrollToLatestMessage();

I changed some of the code above so I can't give exact line numbers.

I hope this points you in the right direction. I'm sure this can be implemented into the chatroom settings so you don't actually have to edit code. I don't have too much free time, but please do contact me if you like to discuss this.

drein’s picture

any news?
I'm interested me too in this topic.
I activated the checkboxes but no sound

ah0’s picture

any updates?
thanks.

greggles’s picture

Title: How to enable sound alerts? » Provide alerts for new messages
Priority: Minor » Normal

There are a few kinds of notifications we could do here, so I'm changing the title.

Those are

1. Use javascript to change the title tag to something that scrolls so the tab becomes more visible
2. Doing a javascript "alert" which will make the browser pull focus into that tab/window
3. Using javascript to play a sound (Google does this for voice calls/chats in gmail)
4. Popping up a separate window

Thanks to pmagunia for the tip on using the soundmanager2 modoule.

My idea is to create a set of preferences so site admins can choose with of those 4 are going to happen on their site. The sound notification could be disabled/hidden unless soundmanager2 module is installed.

c4rl’s picture

Subscribe

Shane Birley’s picture

Issue summary: View changes
Status: Active » Closed (outdated)