• Resolved josh-jones

    (@josh-jones)


    I’ve been trying all night to store the excerpt as a variable for further processing, but it won’t let me… Here’s what I’m using:

    $getExcerpt = get_the_excerpt();

    Now when I echo that:

    echo $getExcerpt;

    It just comes up blank… Nothing.

    However, if I do:

    echo get_the_excerpt();

    Then it returns the excerpt like it’s supposed to! What in the world is going on?

    And yes, I even tried it in the default theme so as to make sure that there wasn’t anything going on in the theme which would cause it. Also, no active plugins… So that’s not the issue either.

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Can’t store excerpt as variable…’ is closed to new replies.