Opened 16 years ago
Closed 16 years ago
#2443 closed defect (bug) (fixed)
Make sure that make_clickable is run before wptexturize
| Reported by: | orioneweb | Owned by: | boonebgorges |
|---|---|---|---|
| Priority: | major | Milestone: | 1.5 |
| Component: | Activity | Version: | |
| Severity: | Keywords: | close | |
| Cc: |
Description
latest wordpress, latest buddypress.
In pages like http://elosnetwork.it/members/USERNAME/ if the user posts something that ends with a link there's a " attached to the link so the link is broken.
For example user posted
abcdefg http://example.com
And buddypress shows (without > and <)
"abcdefg a href=http://example.com" /a with the trailing ", breaking the link
the " should not go in the link but be separated from it
Also, if the user posts www.example.com instead of http://www.example.com the link doesn't seem to be clickable.
Attachments (1)
Change History (8)
#1
in reply to: ↑ description
@
16 years ago
I made sure that this bug also happens in the default buddypress theme on a clean latest wpmu and latest buddypress install
Replying to orioneweb:
latest wordpress, latest buddypress.
In pages like http://elosnetwork.it/members/USERNAME/ if the user posts something that ends with a link there's a " attached to the link so the link is broken.
For example user posted
abcdefg http://example.com
And buddypress shows (without > and <)
"abcdefg a href=http://example.com" /a with the trailing ", breaking the link
the " should not go in the link but be separated from it
Also, if the user posts www.example.com instead of http://www.example.com the link doesn't seem to be clickable.
#2
@
16 years ago
- Priority normal → major
Confirmed in trunk. Any link with a trailing " mangles the <a> link in the header section of a member's profile. The link displays fine in the activity stream.
#3
@
16 years ago
- Keywords close added
I ran a couple of tests and the problem boils down to the make_clickable filter, as applied to bp_get_activity_latest_update_excerpt and bp_get_activity_latest_update in bp-activity-filters.php.
Essentially, I think this is a WordPress problem. The regex in make_clickable and its callbacks doesn't know what to do with a quotation mark at the end of a URL. I tested this in a normal blog post (making sure to add_filter( 'the_content', 'make_clickable' ); )
I vote for marking this ticket invalid, with a suggestion that we send it upstream to WordPress. See #WP10990 #WP5081 for possibly related issues.
#4
@
16 years ago
- Resolution → invalid
- Status new → closed
http://core.trac.wordpress.org/ticket/17097 I've sent this upstream.
#5
@
16 years ago
- Resolution invalid
- Status closed → reopened
- Summary posting links at the end of status updates breaks them in member page → Make sure that make_clickable is run before wptexturize
Reopening this ticket because I've been straightened out a bit on WP trac. The root cause of the problem is not make_clickable() itself, but the fact that BP is not making sure to run it before wptexturize, which is responsible for converting quotes into HTML entities. (WP sets its uses of make_clickable to priority 9.) I've run a preliminary test or two and this seems to fix the problem. I'll sweep through the rest of the components and make sure that it doesn't cause any other problems.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
screenshot example