Definitive answer on Filter_HTML status, update or alternative, please?
Posted: 26 February 2007 01:05 PM   [ Ignore ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1841
Joined  03-26-2006

I have a site running on php 4.4.x and this seems to be the only site that doesn’t want to use filter_HTML correctly. I have gone through and removed ampersands, HOWEVER, this seems to have screwed up the word/character limiting aspect of the plugin. For example, I have this working perfectly on one site:

{exp:filter_html units="words" if_exceeds="20" stop_after="10" rules="-*" ellipsis="&hellip;<a href='{url_title_path=news/article}'>More &raquo;</a>"}{body}{/exp:filter_html}


But when I put it on the site running 4.4.x, everything but the “rules” parameter is ignored.

I was reading this thread about how the original developer “passed the baton”  - and that was late 2005.

I’m trying to reduce load time on a page, and I have the filter_html plugin wrapped in the word_limit plugin. With 5-20 entries on a page, that’s a lot of extra work, especially if the filter_html plugin can just take care of limiting the words itself.

Can someone answer defninitively: Is there a version newer than 1.0, or an alternate plugin I can use to do what it does? I’m going to reinstall this plugin and remove as few ampersands as possible this time to see if I can get it working! Thanks for any help here.

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 26 February 2007 01:25 PM   [ Ignore ]   [ # 1 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1841
Joined  03-26-2006

Also, is anyone else having problems getting the backtick and tilde characters to work in the ellipsis parameter?

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 26 February 2007 02:18 PM   [ Ignore ]   [ # 2 ]  
Moderator
Avatar
RankRankRankRankRankRankRankRank
Total Posts:  33276
Joined  05-14-2004

I can definitively tell you the author for that plugin is gone and it has not been updated and is not being maintained.  Alternates are the word_limit, char_limit plugins shipped with EE, and the Word Limiter plugin.  If these don’t suit your needs, then it would be best to write a new plugin.

 Signature 
Profile
MSG
 
 
Posted: 26 February 2007 02:41 PM   [ Ignore ]   [ # 3 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1841
Joined  03-26-2006
Lisa Wess - 26 February 2007 02:18 PM

I can definitively tell you the author for that plugin is gone and it has not been updated and is not being maintained.  Alternates are the word_limit, char_limit plugins shipped with EE, and the Word Limiter plugin.  If these don’t suit your needs, then it would be best to write a new plugin.

Yeah, I see the original author is using TextPattern, it looks like. Anyway, I thought this got passed off to someone (rob1?) so I was wondering what happened there. I did reinstall the plugin and ONLY replaced those ampersands where it threw an error (instead of just replacing them all) and it seems to be working for me on PHP 4.4.x now (limiting characters and filtering the HTML as it should). I was able to get rid of all the word_limit calls I was making and that definitely helped speed up the page load time.

This is a beautiful plugin - just awesome for doing text excerpts. Guess i’m glad I have it working as much as I do, but would be nice to know someone out there can answer questions - like why the tilde and backtick replacement doesn’t sem to want to work!

My vote is that Mark Huot shold take it over!

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 26 February 2007 02:48 PM   [ Ignore ]   [ # 4 ]  
Moderator
Avatar
RankRankRankRankRankRankRankRank
Total Posts:  33276
Joined  05-14-2004

Robin was going to do minor updates to have it work across PHP versions, but things got really busy here and I’m not sure her free time allowed for it.  Joe is a brilliant coder, but that plugin is extremely complicated, maybe even more than it needed to be?

It also hasn’t been updated since 1.3 (maybe 1.2) of EE - so I would highly recommend that “taking this over” would be a bad idea, but starting from scratch would be optimal. 

I will tell you this - filter_html accounted for a decent portion of my post count (back before I was staff) simply because of how difficult it was to use.

 Signature 
Profile
MSG
 
 
Posted: 26 February 2007 04:34 PM   [ Ignore ]   [ # 5 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1841
Joined  03-26-2006

You’re right - this puppy is very complicated. Powerful, but, sheesh, under the hood it’s madness! I’m not sure it’s as streamlined as it could be either. Then again , I’m more of a CSS/HTML guy, dipping into the PHP only when I have to.

The thing is, once I used filter_HTML I sort of became addicted. How else does one strip out tags to make perfect little excerpts so easily (i.e. removing an article’s lead image)? I know you can wrap a plugin within a plugin, but on the site I’m working on, that’s just not practical as we have up to 30 excerpts on a page. 

Thanks for your responses, Lisa!

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 26 February 2007 05:17 PM   [ Ignore ]   [ # 6 ]  
Moderator
Avatar
RankRankRankRankRankRankRankRank
Total Posts:  33276
Joined  05-14-2004

I honestly think that the plugin could be cleaner and far less confusing to the end-user.  I never really used it because I couldn’t even understand the examples in the documentation. 

I also know that some people have sped up their pages significantly by removing this plugin, so do keep an eye on it.

I don’t code, and I can’t even begin to understand Joe, even when he’s speaking in plain English, most of the time.  He’s just one of those really brilliant folks that’s on a whole other level.  I don’t know that the plugin needed to be that complicated, either.  I always thought there had to be a better way. =)

 Signature 
Profile
MSG
 
 
Posted: 26 February 2007 05:23 PM   [ Ignore ]   [ # 7 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1841
Joined  03-26-2006

I’ll tell you what, if any of these other plugins (word limit plus, etc) can actually remove tags/images etc from a block of text to make an excerpt, then I’d much rather use them. I really think that, as neat as this plugin is - it is KILLING the page load times. I honestly think it is murdering this site I’m working on.

I really need a way to strip out images, and any other taggs (bold, italic) that might get cut in half when taking an excerpt of text - and thus possibly ruining the rest of the page layout. The client commonly puts an image right at the top, and very often uses all sorts of tags. I just need the first 20-30 raw words of a post. Maybe filter HTML is overkill?

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 26 February 2007 05:29 PM   [ Ignore ]   [ # 8 ]  
Moderator
Avatar
RankRankRankRankRankRankRankRank
Total Posts:  33276
Joined  05-14-2004

How about strip HTML along with any of the aforementioned limiters?

 Signature 
Profile
MSG
 
 
Posted: 26 February 2007 06:19 PM   [ Ignore ]   [ # 9 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1841
Joined  03-26-2006

Lisa, thanks for that tip. I just wrote my own (OK, “modified an existing”) plugin, and called it Eexcerpt. It’s basically a cross between word_limit_plus and strip_html. First it takes your text and strips the tags (all of ‘em, no removing one and skipping the other) - then it does the word_limit_plus thing to the resulting text.

I attached version 1.0.0 here in case anyone else wants it.

Seems to do what I had filter_HTML doing with a LOT less overhead. This strips out every tag, folks! It’s down and dirty!

{exp:eexcerpt if_exceeds="42" stop_after="40" the_link='<br /><p class="more_link"><a href="{url_title_path=weblog/article}">More &raquo;</a></p>'}{body}{/exp:eexcerpt}

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 26 February 2007 06:20 PM   [ Ignore ]   [ # 10 ]  
Moderator
Avatar
RankRankRankRankRankRankRankRank
Total Posts:  33276
Joined  05-14-2004

mdesign - does this include original code from those plugins and were you allowed to redistribute your modifications?  Please make sure you have permission and remove this if you don’t, at least until you do. =)

If this is your original work then ignore me.  And thank you!  Please do post it to the plugin library!

 Signature 
Profile
MSG
 
 
Posted: 26 February 2007 06:31 PM   [ Ignore ]   [ # 11 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1841
Joined  03-26-2006

Um er, yeah… I put proper credit in there (basically left everyone’s name in there, and left Rick as the ‘author’) but I did take the plugin down. It uses the bulk of word_limit_plus, which was based on word_limit, and I just threw in the body of a php function I found after googling around to strip out the HTML tags.

I’ll keep it to myself for right now. Have deadlines. Would love to add a few more things to it before passing it along to others - and I should get the proper permission, yeah.

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 26 February 2007 06:42 PM   [ Ignore ]   [ # 12 ]  
Moderator
Avatar
RankRankRankRankRankRankRankRank
Total Posts:  33276
Joined  05-14-2004

Thank you, Ryan. Sorry to throw that issue into here, but alas, it needed doing.  It sounds like an amazing plugin so I do hope you’ll follow through on it. =)

 Signature 
Profile
MSG
 
 
Posted: 26 February 2007 06:57 PM   [ Ignore ]   [ # 13 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1841
Joined  03-26-2006
Lisa Wess - 26 February 2007 06:42 PM

Thank you, Ryan. Sorry to throw that issue into here, but alas, it needed doing.  It sounds like an amazing plugin so I do hope you’ll follow through on it. =)

Lisa, it’s totally fine. One thing I like about this community is the respect people have for others’ work.
So, here’s a line from the plugin:

'pi_author' => 'Rick Ellis; additions by Vik Rubenfeld; then Ryan Masuga',


I have zero info on Vik Rubenfeld - there’s no link in there for Vik, and when I click his name on the plugin page I get an error. How do I quickly find this person?

HEY VIK! PM ME, WOULDJA?

*ahem* Sorry. Bet that didn’t even work.

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 26 February 2007 07:04 PM   [ Ignore ]   [ # 14 ]  
Moderator
Avatar
RankRankRankRankRankRankRankRank
Total Posts:  33276
Joined  05-14-2004

Vik is his name in these forums. =)  Asking me is often a decent way…

Generally that information should be in the licensing/credits but that clearly didn’t happen here.

 Signature 
Profile
MSG
 
 
Posted: 26 February 2007 07:06 PM   [ Ignore ]   [ # 15 ]  
Moderator
Avatar
RankRankRankRankRankRankRankRank
Total Posts:  33276
Joined  05-14-2004

Furthermore I’ll report that error and get that link fixed up.  I think I know what happened there.

 Signature 
Profile
MSG
 
 
Posted: 26 February 2007 07:16 PM   [ Ignore ]   [ # 16 ]  
Lab Technician
Avatar
RankRankRankRank
Total Posts:  1841
Joined  03-26-2006

Yeah, sorry, I found him. I was just being lazy. And trying to be funny. I’m trying to avoid the Simple Commerce part of this site now that I have that speed bottleneck figured out. smile

 Signature 

ryan masuga
—————
Masuga Design | Member, EE Pro Network
My EE Add-Ons | {devot:ee}
Twitter: masuga | masugadesign | devot_ee

Profile
 
 
Posted: 26 February 2007 07:35 PM   [ Ignore ]   [ # 17 ]  
Moderator
Avatar
RankRankRankRankRankRankRankRank
Total Posts:  33276
Joined  05-14-2004

*grins*  I shan’t allow that…. off with you, get to the real work! *ducks*

 Signature 
Profile
MSG
 
 
   
 
 
Post Marker Legend
New Topic New posts Hot Topic Hot Topic with new posts New Poll New Poll Moved Topic Moved Topic Sticky Topic Sticky topic
Old Topic No new posts Hot Old Topic Hot Topic with no new posts Old Poll Old Poll Closed Topic Closed Topic Announcement Announcements
Theme
Change Theme
Visitor Statistics
The most visitors ever was 1149, on July 16, 2007 09:33 AM
Total Registered Members: 66473 Total Logged-in Users: 48
Total Topics: 84876 Total Anonymous Users: 23
Total Replies: 455399 Total Guests: 248
Total Posts: 540275    
Members ( View Memberlist )