Jump to content

A bug in my chat


Recommended Posts

I'm having an issue with my chat where chat posts are not getting inserted when using words like don't or won't.

mysql_query("INSERT INTO chat (poster_id,date,class,poster_name,message,whisper) VALUES ('".$menu['id']."','$date','$class','$name','$message','$whisper_id')");

$message is the text part of the insert.

I've tried "$message", "'.$message.'", and '".$message."' none of it helps. One of them simply changed the issue from ' to " not getting inserted.

Any advice would be great. I'm a bit rusty on my coding skills as I haven't done it it awhile.

Link to comment
Share on other sites




I cant remember which is correct, been so long since i had to use those fumctions.

Change your database encoding to UTF-8 should help(i could be wrong).

  • Thanks 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...