Help Center Live Community
April 25, 2014, 03:26:51 AM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: 1 [2]   Go Down
  Print  
Author Topic: Loosing Messages  (Read 18891 times)
spatter9999
Not too much to say...
*
Offline Offline

Posts: 3


« Reply #15 on: March 08, 2008, 07:09:52 PM »

UPDATE:

I'm using the Bliss template... so I edited the file ../templates/Bliss/chat_send.tpl

I changed:
Code:
<input type="text" autocomplete="off" name="chat_box" id="chat_box" size="30" maxlength="150" onkeypress="parent....
to:
Code:
<input type="text" autocomplete="off" name="chat_box" id="chat_box" size="30" maxlength="500" onkeypress="parent....

But it didn't work like I wanted.  It will now let the operator and end-user type up to 500 characters, BUT...
1) It pops up a message saying the message is too long and will be trucated.  (It truncates down to 300 characters)
2) It displays the new truncated 300 char message to the display of the person who typed it, but not to the other user

Nothing over 150 char seems to get written to the database and shown to the other person.

Please help... I have to get this thing running this weekend.
Logged
enkidu
Not too much to say...
*
Offline Offline

Posts: 4


« Reply #16 on: November 25, 2008, 12:35:26 AM »

"bump" Can anybody please answer honestly to this question:  Can this problem (150 limit) be solved or not?

 Don't meant to be rude but. . .  chat application with 150 character limit?  :D

 ( by the way - search on this forum gives a random answers.  Feature or bug? )
« Last Edit: November 25, 2008, 12:59:32 AM by enkidu » Logged
petro
Not too much to say...
*
Offline Offline

Posts: 1


« Reply #17 on: November 25, 2008, 09:39:04 AM »

storing "yes" in a 4000 char length varchar field do not take 4000 bytes.   
Actually it requires 4 bytes.  

hxxp: dev.   mysql.   com/doc/refman/5.   0/en/char.   html

Quote from: HCL Admin link=topic=279.   msg1700#msg1700 date=1194953457
It looks like the code is trying to avoid a potential mysql error, and is a bit over zealous about it.     I'm trying to figure out a graceful way to do it that doesn't eliminate the ability to extend the limit.    

BTW that limit is there to prevent the database from becoming overly large.     If the field size is 4000 characters, even sending "yes" would take 4000 bytes of hard drive.     Some shared hosts might not be happy if you have 27 gigabytes of database.    :)
Logged
kirpi
Not too much to say...
*
Offline Offline

Posts: 3


WWW
« Reply #18 on: December 03, 2008, 10:12:38 PM »

> that limit is there to prevent the database
> from becoming overly large.         

I suggest that, if any limit is set, a counter is shown while the user is typing, which tells how many characters are left for the message.   Most probably there are many ways to achieve this[1].      

Luigi

----
[1] hxxp: www. quirksmode. org/dom/maxlength. html just being a mere example.      
« Last Edit: December 04, 2008, 01:14:27 AM by kirpi » Logged
Pages: 1 [2]   Go Up
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.8 | SMF © 2006-2008, Simple Machines LLC Valid XHTML 1.0! Valid CSS!
Page created in 0.149 seconds with 19 queries.

Google visited last this page April 13, 2014, 08:58:26 PM