MyBB Community Forums

Full Version: Smilies and space problem [R]
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
If there's no space after the code for an emoticon it does not get parsed.

Example:
1. Test Rolleyes Test
2. TestRolleyes Test
3. Test RolleyesTest
This is done on purposes from previous bugs relating to smilies.
Why is it parsing when there is no space infront of the smilie then?Smile
(2008-11-12, 12:02 PM)CraKteR Wrote: [ -> ]Why is it parsing when there is no space infront of the smilie then?Smile

Because people complain back and forth on this issue infinitely and it ended up like that for the 1.4 release.

As far as I am concerned this is not a real bug because that is how it was designed, ever so wrong it may be in your opinion.


I'm happy to consider this a suggestion for a better solution in a future version.
If the issue was server side, the zero width unicode character could be used to act as a delimiter for smiley codes. However I know of no forum software that does this, while the zero width character has some legitimate uses, using it for smileys would be more of a hack than anything else. The main problem is that users have to be able to edit the text so you shouldn't use any special characters or delimiters at all.

I have not looked at the background or reasoning behind the space issue here, but maybe it would help users to change the JavaScript that inserts the smiley codes, so that it does not only insert the code, but also adds in the necessary space, if there is no space at the insert point anyway. This way, if you click a smiley button in the middle of text or continue typing directly after the inserted code, they would actually get the smiley they clicked and not a code that can't be interpreted.

Of course if the smiley parser could be modified in some way that drops the requirement altogether that would be the best solution. I'll have a look at it sometime later. But it seems to work quite well already, as it understands (Cool). I've seen other forums display it as (:cool Smile.
I'm deferring this as a suggestion based on frostschutz "space javascript" suggestion