1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

As Designed Smilies parsing being done on parts of words

Discussion in 'Resolved Bug Reports' started by digitalpoint, Dec 28, 2012.

  1. digitalpoint

    digitalpoint Well-Known Member

    If you write this in a post, XenForo_Model_Thread::prepareThreadFetchOptions() the middle of it is parsed as a smiley like so: XenForo_Model_Thread::prepareThreadFetchOptions()

    I'm using the [plain] BBCode to actually make it work in case you are wondering. :)

    Maybe require white space around smilies in order to auto-parse them into images?
     
    Adam Howard, HWS, Alfa1 and 3 others like this.
  2. Chris D

    Chris D XenForo Developer Staff Member

    I agree.... and let me just test something...

    I went to a place called Scunthorpe a few weeks ago...

    Yep... similar issue with the censor words... though slightly less of a problem with that. As you probably wouldn't want someone circumventing it by stringing swears together.

    ********cunt.

    Though, I just feel sorry for people from Scunthrope :ROFLMAO:
     
    0xym0r0n and Jake Bunce like this.
  3. Jake Bunce

    Jake Bunce XenForo Moderator Staff Member

    This seems like something you should just live with. Requiring white space seems a "not necessarily correct" solution as there are legitimate use cases without white space. An explicit way to handle parsing problems seems the best way (ie the plain tag).
     
  4. digitalpoint

    digitalpoint Well-Known Member

    Agreed that there are edge cases where you wouldn't want white space... But would you tether sometimes see a smile without the image or sometimes see an image in the middle of a word? Maybe if there isn't alpha characters surrounding or something.
     
  5. BamaStangGuy

    BamaStangGuy Well-Known Member

    They didn't seem to care a year ago: http://xenforo.com/community/threads/no-censor-action-on-urls.13249/#post-299263
     
  6. Luke F

    Luke F Well-Known Member

    Can't think of any to be honest

    If someone types a smiley touching a word, I highly doubt they want it converted to an image
     
    HWS likes this.
  7. Jeremy P

    Jeremy P Well-Known Member

    +1 for requiring whitespace/newline before smileys

    I'd think you'd want this behavior more than not.
     
    HWS likes this.
  8. Alfa1

    Alfa1 Well-Known Member

    I don't care about legitimate cases to use smilies without white space. The instances where smilies are inaccurately added are much larger and much more annoying.
     
    HWS, digitalpoint and Jeremy P like this.
  9. Mike

    Mike XenForo Developer Staff Member

    So currently, this is as designed. I'm not against necessarily changing in the future, but it would involve a big change to the smiley parsing mechanism, and it'd likely end up moving to a much slower method (unfortunately).
     
    Digital Doctor and Slavik like this.
  10. HWS

    HWS Well-Known Member

    Can you pls reconsider that?
    The current implementation leaves to many users wondering why smileys pop up they never intended to use. I second Alfa1s observations.
     
    Jeremy P likes this.
  11. Luxus

    Luxus Well-Known Member

    How about adding a checkbox beneth the editor that disables all smilie parsing in a post when checked?
     
  12. CyclingTribe

    CyclingTribe Well-Known Member

    Alternatively, what about changing the default smiliey BBCode tags so that for future (new) installs they will use a more friendly tagging convention (and hopefully people will follow it with any new ones they add of their own). E.g.;

    ::smile::
    ::grin::
    ::barefoot:: <--- lol
    ::angry::

    You get the idea ... ::thumbs-up::
     
  13. HWS

    HWS Well-Known Member

    You can do this yourself already.
    But if you want the standard smiley codes ;-) :) to work, you have no chance currently.
     
  14. AndyB

    AndyB Well-Known Member

    The solution to this problem is rather simple. The
    I suggest not using the simple smilie codes that end in one alpha character. The tongue smile should be renamed to :tongue and that will solve this problem.
     
  15. Chris D

    Chris D XenForo Developer Staff Member

    Yet cause so many more.


    It just isn't intuitive to change what has been internationally recognised smilies for nearly 20 years just because the software on very rare occasions converts text it shouldn't do into smilies.

    The correct solution to the problem is to be aware of it, and wrap your text like this: [plain]XenForo_Model_Thread:prepareThreadFetchOptions()[/plain]

    The [plain] bb code[/plain] prevents BB Code and Smilies from being parsed.
     
    0xym0r0n, Luxus and Biker like this.
  16. tenants

    tenants Well-Known Member

    Not just alpha characters, but internationalisation characters and numbers too ... if a smiley concatenates anything but a space, or endofline, then it's unlikely to be an intentional smiley

    Together, the following smiles occur common enough, that most users will have seen the issue within their 1st 100-200 posts (I've hit it at least 5 times)


    :D
    8-)
    :o
    :(
    >:(
    :@
    :)
    :-)
    (:
    o_O
    O_o
    o.O
    O.o
    :p
    :P
    :-p
    :-P
    ;)


    As more smiles are extended/added, it becomes more common. I've seen quite a few users mentioning the smiles issue, I doubt there would be complaints of users not being able to produce smiles with:-\in the middle of a word ... and if they did have complaints, then it's this case that should have a work around (for instances, use a text version like : barefeet : )
     
  17. Biker

    Biker Well-Known Member

    Learned something new today. I've always used code tags when I didn't want something to be parsed into smilies.
     
    CyclingTribe likes this.
  18. CyclingTribe

    CyclingTribe Well-Known Member

    Me too:)
     
  19. Brogan

    Brogan XenForo Moderator Staff Member

  20. Biker

    Biker Well-Known Member

    CyclingTribe likes this.

Share This Page