• (Cross-post; originally posted here before I realized which forum I was actually in. This one seems like a better choice.)

    I followed the suggestion here to successfully end up with a front page that publishes excerpts … but not the way I was hoping it would.

    I would like full entries to appear on the homepage for all entries for which the excerpt block was left blank, and for excerpts to appear only for entries for which an excerpt was entered during post creation. Seems like this should be the default function … but, instead, I now have excerpts only for ALL entries.

    Help?

Viewing 9 replies - 1 through 9 (of 9 total)
  • Using the_excerpt you always get an excerpt. If you haven’t entered one, WP creates one by pulling the first part of your post content. This makes sense to me….if you ask for an excerpt, you get one.

    Thread Starter jzahlaway

    (@jzahlaway)

    That doesn’t answer my question.

    You are going to have to do a test on the DB.

    Run a query to check if the excerpt field is empty in the DB for the post you are processing. If it’s empty, call the_content. If not, call the_excerpt.

    It’s going to require a little hacking.

    Thread Starter jzahlaway

    (@jzahlaway)

    Serious question (really not trying to sound like a smartass; this is my first day on this board, so I’m not yet clear about what the average level of skill is assumed to be.):

    Is it assumed that the skill level of the average user posting on this board is such that the response above–concluding with “It’s going to require a little hacking”–sufficiently answers the question “How do I get full entries to appear on the homepage for all entries for which the excerpt block was left blank, and for excerpts to appear only for entries for which an excerpt was entered during post creation?”? If so, does anyone know of a board where the learning curve starts a little lower?

    No, the average skill level isn’t a assumed to be that of a hacker.

    But that is in essence what you’re asking for and I was just letting you know that. It’s going to require some custom code to do what you want.

    Sorry if I sounded out of line. I was just trying to answer your question as quickly as possible.

    Serious answer 🙂
    The answer you’ve got to your question tells that to achieve what you wish requires coding knowledge (a.k.a. “hacking”) otherwise it is not possible. It also says there is no such hack (yet). If it was, they would have linked to it.

    As it is for the moment you can either call for the whole post or for excerpt for ALL the entries. Actually a kind of workaround would be to use the <more> tag for certain posts and not to use it for others.
    Hope this helps.

    Well said moshu. Thanks for clearning that up. 🙂

    Thread Starter jzahlaway

    (@jzahlaway)

    Thanks, guys.
    I know how to write PHP, but it seems navigating through the various includes/etc. to find what I need is going to be tricky.

    I’m surprised that the result I wish to achieve is such an anomaly; seems like a no-brainer setting that would/should be built in.

    Edit: The <!–more–> tag is a pretty good workaround. I wasn’t aware of its existence before. Thanks for the tip!

    I posted a reply here

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘Mix of excerpts and full entries on front page?’ is closed to new replies.