Skip to main content
6 events
when toggle format what by license comment
Aug 29, 2013 at 11:21 comment added bueltge Use the function get_the_excerpt() , there have a return, no echo. A example $my_excerpt = get_the_excerpt(); if ( $my_excerpt != '' ) { // todo }
Aug 28, 2013 at 14:13 comment added Ayyash How do you check the excerpt is empty?
Feb 20, 2013 at 13:06 vote accept mathiregister
Feb 20, 2013 at 12:57 comment added bueltge Write you a custom function, there check for the excerpt and if empty, then use my example. This custom function include in your sprintf().
Feb 20, 2013 at 12:51 comment added mathiregister thank you, but how do I use that in my sample code above. How is the_excerpt used if an excerpt is set, but the stripped/trimmed content used when no excerpt is set? What is the cleanes solution for that?
Feb 20, 2013 at 12:46 history answered bueltge CC BY-SA 3.0