WordPress.org

Support

Support » Plugins and Hacks » Get string from excerpt

Get string from excerpt

  • Hi, i want to use store the string from excerpt field in wordpress post table to variable and this is what i’m writing:

    $excerpt_str = the_excerpt()
    echo $excerpt_str

    i want to store the string from excerpt to the variable excerpt_str,
    but it doesn’t work the way it suppose to be…
    any solution, thanks…..

Viewing 2 replies - 1 through 2 (of 2 total)
  • Have you tried get_the_excerpt() ?

    it works, thanks
    but here’s the tricky part. I want to use that with sql string to write another plugin

    $result = mysql_query("SELECT * FROM aniwo_posts
    WHERE aniwo_content='$excerpt_str'");

    and the result doesn’t come out. Any solutions? thanks..

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Get string from excerpt’ is closed to new replies.
Skip to toolbar