EllisLab text mark
Advanced Search
     
Announcing: Hop Inject, for injecting text into your custom fields
Posted: 19 October 2009 07:55 PM   [ Ignore ]
Avatar
Joined: 2007-05-02
147 posts

We developed Hop Inject to solve a very specific problem: We wanted to place advertisement blocks after the 3rd (or 8th, or 3rd AND 8th) paragraph on a page.  But, since this is EE we’re talking about, of course the 3rd (etc.) paragraphs were in a custom field of an entry, and were being rendered dynamically at request time.

Hop Inject does the trick.  It lets us specify where an injection should occur (such as, “on paragraph tags”); it lets us specify which of those separators should get the injection (for example, “the third and the eighth”); and it lets us specify what the injection should be.  It also lets us choose whether the injection should occur before or after the separator.

Sound like a problem you’ve run into, too?  Well, it’s not a problem anymore!

You can download Hop Inject here.

Let us know how you like it!

Justin

 
Posted: 20 October 2009 03:05 PM   [ Ignore ]   [ # 1 ]   [ Rating: 0 ]
Avatar
Joined: 2009-01-19
235 posts

Awesome - I was literally just walking home thinking how am I gonna solve a particular problem in an upcoming job - this sounds perfect.

what I was trying to do was provide a single content field (with WYSIWYG editor no doubt) that will be used to display album reviews. The tricky part was they were to fit in a fixed height space on the page, so I was planning on using a jQuery carousel to essentially paginate these reviews up into several carousel slides.

So the tricky bit was being able to tell jQuery / DOM where to cut each page up at - if this does what I think it does, I would presumably be able to specify that on page break tags <‘br> it inject the code needed to end one slide and open another.
Then its just up to the reviewer to put those breaks in and you’ve got easy, self controlled pagination for a jQuery carousel.

Really hoping its gonna work!!

 Signature 

moogaloo.com

twitter | facebook | dribbble

Free Agent - invoicing, time tracking & accounting made easy - 10% off for life.

 
Posted: 22 January 2010 01:24 PM   [ Ignore ]   [ # 2 ]   [ Rating: 0 ]
Avatar
Joined: 2006-09-06
513 posts

I’m looking to insert a formatted “more” link just inside the last paragraph at the end of the last paragraph in a custom field before the closing tag, like:

<p>A first paragraph</p>
<
p>Possibly a second paragraph</p>
<
p>The last paragraph <span class="this_is_the_part_I_want_to_inject"><a href='#'>more</a></span></p

Is this doable?

 Signature 

Kyle Summer | smartpill design | New Haven, CT |  twitter

 
Posted: 09 April 2010 05:32 PM   [ Ignore ]   [ # 3 ]   [ Rating: 0 ]
Avatar
Joined: 2010-02-20
182 posts

Thank you, thank you, thank you for this plugin!

I was looking for a way to automatically insert Adsense into every article, and it worked great!

 Signature 

www.alternativa-za-vas.com

 
Posted: 12 May 2010 04:58 PM   [ Ignore ]   [ # 4 ]   [ Rating: 0 ]
Avatar
Joined: 2007-12-08
539 posts
Hoosteeno - 19 October 2009 11:55 PM

...

Let us know how you like it!

Justin

I do like it! Thanks very much. It solved a very specific problem for us too and worked exactly as documented. Nice plug-in!

 Signature 

www.pixogee.com EE Pro Network