Closed (fixed)
Project:
Field HTML Trim
Version:
7.x-1.2
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
29 Jun 2014 at 23:53 UTC
Updated:
1 Feb 2016 at 10:49 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
alexverb commentedI'll have to investigate this one because there are still some issues in core 7.x with the break comment for filtered html and text. See Regression: 'break' tag doesn't work with Filtered HTML.
Could you provide me with a use case for this feature? Because I don't want to put too much effort into this feature that isn't going to work anywayz for filtered html and text.
Comment #2
alexverb commentedWith this patch I've added the functionality you've requested. Now it's possible to use the breakpoint comment to cut off the text wherever you want. Even if the breakpoint is located after the set trim length. So it's possible to manually shorten or lengthen your text without counting the HTML.
Is it possible for you to do some testing on my patch before I commit?
Comment #3
lolandese commentedI recommend this module in combination with the Flickr module. AFAIK till today it is the only module that can exclude HTML from the teaser character count. The embedded HTML generated by the Flickr module is often placed at the beginning of the first paragraph.
I will test your patch asap (latest tomorrow).
Thanks.
Comment #4
lolandese commentedSorry about the belated reaction. Previously I made a mess wanting to test it together with the Flickr module (Flickr Filter) but that seems to have problems with the teaser even with core. I should test that module separately.
Continuing more cleanly:
Test URL:
https://simplytest.me/project/field_html_trim/7.x-1.x?patch[]=https://ww...
Steps after launch:
All looks as expected.
I have some inconsistency when combined with HTML on the number of characters (see screenshot). Obviously that is another issue.
Comment #6
alexverb commentedThis feature is added in 7.x-1.2. Thx for the testing lolandese. I'll see if I can find some time to investigate the inconsistency on character count when HTML is used. But feel free to open another issue if you find such a case that can be easily replicated.
Comment #7
alexverb commentedAlso a note to lolandese, I found the culprit of the inconsistancy in character count and made a new issue for that one. I just have to figure out the correct way to set up the word pattern. Shouldn't take all too long. See related issue.
Comment #8
lolandese commentedMaybe my test.txt with mostly numbers is a worst case scenario. Obviously it was just intended to easily check on the number of characters in the teaser.
Thanks for the latest improvements. I'm following the other issue with interest.
Comment #9
alexverb commentedFixed in 7.x-1.3