Chat room: Message are not being sent

beautifulmind - May 11, 2009 - 12:15
Project:Chat Room
Version:6.x-2.3
Component:User interface
Category:bug report
Priority:critical
Assigned:justinrandell
Status:fixed
Description

I am using chat room 6.x-1.0-beta2 and I'm unable to send message. there is now way.

#1

justinrandell - November 9, 2009 - 14:46
Version:6.x-1.0-beta2» 6.x-1.0-beta10
Status:active» fixed

please reopen this if you can reproduce in the latest beta or in the 6.x-2 branch.

#2

BManuel - November 11, 2009 - 00:12

Can't send a message on IE. Little Icon on bottom left shows an error
Webpage error details

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; WOW64; Trident/4.0; Comcast Install 1.0; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.5.30729; .NET CLR 3.0.30729)
Timestamp: Tue, 10 Nov 2009 22:37:03 UTC

Message: Expected identifier, string or number
Line: 86
Char: 5
Code: 0
URI: /sites/all/modules/chatroom/chatroom.js?l

#3

justinrandell - November 11, 2009 - 08:32
Version:6.x-1.0-beta10» 6.x-2.x-dev
Status:fixed» active

BManuel, thanks for the report, which version of the code are you using?

if you're trying the module for the first time, i'd recommend using the 6.x-2 code, as the 6.x-1 code is slow and buggy, and i'll be deprecating it shortly.

#4

BManuel - November 11, 2009 - 21:27
Priority:normal» critical

Testing with 6.2 and thanks for taking my advice on button. Great work! However when I click it I get this error.

Webpage error details
User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; WOW64; Trident/4.0; Comcast Install 1.0; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.5.30729; .NET CLR 3.0.30729)
Timestamp: Wed, 11 Nov 2009 20:34:10 UTC

Message: Expected identifier, string or number
Line: 86
Char: 5
Code: 0
URI: sites/all/modules/chatroom/chatroom.js?l

So I thought I investigate (get my hands dirty) and
I think this may be a syntax error.
Komodo editor says "strict warning: trailing comma is not legal in ECMA-262 object initializers (on column 21)

It is on line "86" and type is "warning" .

After you fix can you pls explain to me what this means. Like to learn a little, so I can help better in future

#5

justinrandell - November 12, 2009 - 01:59
Title:Chate room: Message are not being sent» Chat room: Message are not being sent
Assigned to:Anonymous» justinrandell
Status:active» fixed

ah, it means that IE is choking on the comma at the end of the last line of this object definition:

<?php
  data
: {
     
latest_msg_id: Drupal.settings.chatroom.latestMsgId,
     
chat_cache_directory: Drupal.settings.chatroom.cacheDirectory,
     
chat_id: Drupal.settings.chatroom.chatId,
     
skip_cache: skipCacheCheck,
     
successive_cache_hits: Drupal.settings.chatroom.successiveCacheHits,
  }
?>

i've committed a fix here, thanks for the report:

http://drupal.org/cvs?commit=288018

#6

justinrandell - November 22, 2009 - 09:56
Status:fixed» closed

#7

pixelchen - November 24, 2009 - 10:58
Version:6.x-2.x-dev» 6.x-2.3
Status:closed» active

I use Drupal 6.14 and IE7
The version 2.3
I cant send a message because Javascript error like this
Line 87
Zeichen 5
Error Bezeichner, Zeichenfolge oder Zahl erwartet
Code 0

then
Line 26
Zeichen 1
Drupal.chatroom ist Null oder kein Objekt

on Firefox is no Javascript error but the new message is not shown since I leaf the chat and come back

#8

justinrandell - November 24, 2009 - 14:05

i'll have to get an IE7 setup to test this. any chance of a screenshot?

#9

andrea.vivaldi - December 2, 2009 - 13:02

Hi, i'm using 2.5 chat room version... i had problems with IE8.
It came out that there was an error in the file "chatroom.js" at line 85.
I fix the problem changing line 85 from :

uid: uid,

to

uid: uid

I hope this will be helpfull. Im my case work fine

Andrea

#10

justinrandell - December 2, 2009 - 15:06
Status:active» fixed

argh, thought i'd got all the trailing ',' - thanks for the fix, committed here:

http://drupal.org/cvs?commit=296810

#11

andrea.vivaldi - December 3, 2009 - 09:13

commas are my nightmares too... :-D

 
 

Drupal is a registered trademark of Dries Buytaert.