808 | | $desc = str_replace(array("\n", "\r"), ' ', esc_attr(strip_tags(@html_entity_decode($item->get_description(), ENT_QUOTES, get_option('blog_charset'))))); |
809 | | $desc = wp_html_excerpt( $desc, 360 ) . ' […]'; |
| 808 | $desc = str_replace( array("\n", "\r"), ' ', esc_attr( strip_tags( @html_entity_decode( $item->get_description(), ENT_QUOTES, get_option('blog_charset') ) ) ) ); |
| 809 | $desc = wp_html_excerpt( $desc, 360 ); |
| 810 | |
| 811 | // Append ellipsis if there isn't one at the end already. |
| 812 | // Change an existing [...] at the end of an excerpt to […]. |
| 813 | if ( !preg_match( '/(\[…\]|\[...\])$/D', $desc ) ) |
| 814 | $desc .= ' […]'; |
| 815 | else |
| 816 | $desc = preg_replace( '/\[...\]$/D', ' […]', $desc ); |
| 817 | |