[wp-trac] [WordPress Trac] #32787: make_clickable filter

WordPress Trac noreply at wordpress.org
Sat Apr 23 17:39:26 UTC 2016


#32787: make_clickable filter
-------------------------------------+------------------------------
 Reporter:  tlexcellent              |       Owner:  johnjamesjacoby
     Type:  enhancement              |      Status:  assigned
 Priority:  normal                   |   Milestone:  4.6
Component:  Formatting               |     Version:  0.71
 Severity:  normal                   |  Resolution:
 Keywords:  needs-patch 2nd-opinion  |     Focuses:
-------------------------------------+------------------------------
Changes (by johnjamesjacoby):

 * keywords:  needs-patch reporter-feedback => needs-patch 2nd-opinion
 * owner:   => johnjamesjacoby
 * version:  4.2.2 => 0.71
 * status:  new => assigned
 * milestone:  Awaiting Review => 4.6


Comment:

 I think I have a great example for adding a filter to `make_clickable` and
 I'll offer up a patch soon also.

 BuddyPress, bbPress, and the P2 theme all use their own (but similar)
 approach to making usernames clickable using `@` as a control character.
 If there were a filter in `make_clickable` vs. the currently hard-coded
 callbacks, these three projects could eliminate some duplication, and use
 a more reliable core filter vs. their own regex.

 bbPress, for example, would deprecate 5 functions if this were possible.

 Once patched, I'd like to champion for this to happen in 4.6. Performance
 with a filter will be only slightly negligible, but any plugin wanting to
 make anything in content blocks clickable with custom parameters will see
 relatively good performance gains from the consolidation of their logic.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/32787#comment:7>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list