#6739 closed defect (bug) (wontfix)
smilie regular expression issue
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | |
Component: | General | Keywords: | |
Focuses: | Cc: |
Description
There is an issue with $wp_smiliessearch, it will miss some valid smilies.
For example, for :) the pattern is:
/(\s|)\:\)(\s|$)/
If the input is ":) :) :) :)"
It will produce only two smilies.
The fix is to change the pattern to:
/(\s*|)\:\)(\s|$)/
Attachments (2)
Change History (7)
#1
@
16 years ago
- Summary changed from smilie regular experssion issue to smilie regular expression issue
#2
@
16 years ago
- Milestone changed from 2.7 to 2.8
What are some of the potential downsides to a more liberal expression? Can you think of any cases where we'd accidentally make a smiley where there shouldn't be one?
#3
@
16 years ago
There are some issues with making it more liberal. There are even some issues right now as can be seen in some themes, like the one Matt uses. See attached screenshot for how it looks when a post has 8 comments which the theme shows as (8) which is replaced with (<img src="icon-cool.gif"> or so, which is then parsed as the appropriate markup.
patch