Jump to content


Photo
- - - - -

Before_Excerpt or After_Excerpt - What am I missing?


  • Please log in to reply
7 replies to this topic

#1 onlinetracker

onlinetracker

    Super Member

  • Members

  • 154 posts
  • Country: Country Flag

Posted 06 July 2013 - 02:11 PM

I have a site that I use to aggregate data that I'm interested in. As such, I don't need excerpts and I don't need post pages. Just the blog page and titles. That said, I use additional plugins that need to go under the title and the meta bar.

 

When I disable the Excerpts on the blog page, it also takes with it the "before_excerpt" and "after_excerpt" hooks. I've never created my own hook, not sure of what flaming hoops would be required.

 

So, my question is... am I missing something and there is a hook before the excerpt or after the title and meta bar that I can throw some functions at which won't be disabled when I disable excerpts?

 

Thanks for any help.

 

ps.. for those curious, the reason I disable excerpts is because some sources don't provide a proper source rss and so the excerpt has a huge amount of data and the Pagelines control panel section that says to limit the excerpt to 55 words has never worked for me on any of my sites.



#2 Rob

Rob

    One Smart Egg

  • Members
  • 13575 posts
  • LocationEast Coast, USA
  • Framework Version:The Latest, of course
  • Country: Country Flag

Posted 06 July 2013 - 04:15 PM

Hi.

 

First, to stop excerpts, you could set the number of words to zero (0) rather than disabling excerpts.

 

Next, you can use our Action Map plugin (free in our Store0 to find out where a hook should go, then, our Hooker plugin (premium in the Store) lets you select the hook (found with Action Map) from a drop down list, then just paste your code. Once saved, the hook should work.

 

There are plugins out there that convert RSS feeds to posts for aggregators.



#3 onlinetracker

onlinetracker

    Super Member

  • Members

  • 154 posts
  • Country: Country Flag

Posted 06 July 2013 - 04:37 PM

Hi.

 

First, to stop excerpts, you could set the number of words to zero (0) rather than disabling excerpts.

 

Next, you can use our Action Map plugin (free in our Store0 to find out where a hook should go, then, our Hooker plugin (premium in the Store) lets you select the hook (found with Action Map) from a drop down list, then just paste your code. Once saved, the hook should work.

 

There are plugins out there that convert RSS feeds to posts for aggregators.

 

@

Please Login or Register to see this Hidden Content

 

Like I said in the original post, that excerpt limiter has never worked for me for any . I figured it was something I'm doing wrong, so I never bother with it. I've changed it to 0 in past, and its done zilch.  The action map plugin is great for finding the hooks, but I've not used Hooker. I thought it doesn't create new hooks, only the ones in place and makes it easy to inject code.

 

Yep. I use a plugin for aggregation. That part isn't a problem.



#4 Rob

Rob

    One Smart Egg

  • Members
  • 13575 posts
  • LocationEast Coast, USA
  • Framework Version:The Latest, of course
  • Country: Country Flag

Posted 06 July 2013 - 05:04 PM

 

When I disable the Excerpts on the blog page, it also takes with it the "before_excerpt" and "after_excerpt" hooks. I've never created my own hook, not sure of what flaming hoops would be required.

Hooker does allow you to inject your own code into a hook.  However, if you're trying to edit code, that's a completely different animal.  You'd need to follow the customization guidelines at

Please Login or Register to see this Hidden Content

.  My answer was an effort to help you skip a few hoops in 'creating your own hook'.

 

In that, you're saying that going to Dashboard > PageLines > Blog And Posts and unchecking the box to display excerpts on the blog page also disables the pre and post excerpt hooks?

 

 

So, my question is... am I missing something and there is a hook before the excerpt or after the title and meta bar that I can throw some functions at which won't be disabled when I disable excerpts?

 

Hard to say, since we're not developers in this forum, for the most part.  You seem to be looking for something that is outside the normal functionality of PageLines Framework, that needs a professional developer.  Action Map should tell you what hooks there are, but I think you're presuming this is solved with a hook.  I don't see that being the answer.  Rather, I think this needs a customization of the postloop section, ported to Base Theme (see the Customization link above). 

 

Like I said in the original post, that excerpt limiter has never worked for me for any .

 

Sorry, I didn't see this information anywhere in your original posting that setting the value to 0 would or did not work.

 

 

The action map plugin is great for finding the hooks, but I've not used Hooker. I thought it doesn't create new hooks, only the ones in place and makes it easy to inject code.

You seem to have a misunderstanding of hooks.  The hook is always there.  It's the function you add to the hook that changes.  You do not create new hooks.  You create new functions within the hook.  I know, the terminology is confusing, as we always say to create a hook, but we're really saying to add a function to a hook.  Sorry about that.

 

To clarify, using Action Map, finding the 'hook', Hooker lets you add the function to the hook so that you can modify or add to the functionality of the site.

 

You should also be aware that you can tell PageLines to not display the excerpts using CSS. Were you aware of that?



#5 onlinetracker

onlinetracker

    Super Member

  • Members

  • 154 posts
  • Country: Country Flag

Posted 06 July 2013 - 05:16 PM

@

Please Login or Register to see this Hidden Content

 

Precisely... if I disable the excerpt in the control panel, so goes away before and after excerpt hooks. If those stayed, but the excerpt went away, this would be a non-issue. I would imagine keeping a hook in place, but disabling what comes after it would be supremely advantageous.

 

Was I aware that I can hide excerpts? Are you kidding? I wouldn't be bugging you with this stupid question. I'm assuming it would still process the excerpt, just hide it. Either way... fill me in because I'm obviously a derp.

 

Thanks



#6 Rob

Rob

    One Smart Egg

  • Members
  • 13575 posts
  • LocationEast Coast, USA
  • Framework Version:The Latest, of course
  • Country: Country Flag

Posted 06 July 2013 - 05:20 PM

Insulting those trying to assist you is not acceptable in this forum. 

 

I will defer this topic to my management.  Thank you.



#7 onlinetracker

onlinetracker

    Super Member

  • Members

  • 154 posts
  • Country: Country Flag

Posted 06 July 2013 - 05:24 PM

@

Please Login or Register to see this Hidden Content

, how did I insult you? I didn't mean to. I'm calling myself a derp, not you.



#8 Rob

Rob

    One Smart Egg

  • Members
  • 13575 posts
  • LocationEast Coast, USA
  • Framework Version:The Latest, of course
  • Country: Country Flag

Posted 06 July 2013 - 07:58 PM

If you use Firebug for Firefox or Chrome's inspection tools, you can select the blog page's excerpt field and use CSS to hide it. Yes, it is called, but it is also hidden, immediately. Once the text itself is hidden, all the hooks surrounding it remain intact, so if you need something from them, they remain available to you.