Opened 12 years ago
Last modified 6 years ago
#23975 new defect (bug)
force_balance_tags in get_the_content breaks non-HTML formats
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 2.8 |
Component: | Formatting | Keywords: | |
Focuses: | Cc: |
Description
The change in r11398 (to fix #9765) breaks Markdown formatted articles that use angle bracket links: <http://example.com/>
turning it into <http: //example.com></http:>
.
If we call force_balance_tags after adding the more link, we need to establish filter hooks for formatters. This should have happened before r11398 already, but because balancing tags wasn't forced, this issue has not affected sites that disable balancing tags in their preferences.
Typically formatters attach to the the_content
filter (among others). This should probably change into a get_the_content
filter (similar to get_the_excerpt
) that is called early on the full content of the post.
I haven't yet decided where the best place for the new filter would, or if it would be better to undo the force_balance_tags call.
Thoughts? I could work on the change, but would rather prefer some input first.
Attachments (1)
Change History (4)
#2
@
11 years ago
- Milestone changed from Awaiting Review to Future Release
Hi ruckus, sorry you never got any direction on this one. That's a pretty old change you cite.
I think force_balance_tags() definitely makes sense here, but I also understand why this could cause problems. Perhaps tag balancing could be made smarter to not catch angle brackets used in this way. I agree that moving this to a filter could be a good idea.
Not a proposed fix, just showing a change that reverts to calling balanceTags but leaving the call after adding the more link.