[wp-trac] [WordPress Trac] #57987: Introduce new `wp_word_count` function

WordPress Trac noreply at wordpress.org
Mon Aug 25 05:55:06 UTC 2025


#57987: Introduce new `wp_word_count` function
-------------------------------------------------+-------------------------
 Reporter:  wildworks                            |       Owner:  pbearne
     Type:  enhancement                          |      Status:  assigned
 Priority:  normal                               |   Milestone:  6.9
Component:  Editor                               |     Version:
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch has-unit-tests needs-      |     Focuses:
  testing                                        |
-------------------------------------------------+-------------------------
Changes (by oglekler):

 * keywords:  has-patch has-unit-tests => has-patch has-unit-tests needs-
     testing


Comment:

 Adding needs-testing.

 Function wp_word_count() can be used to count the words in the

 {{{
 $content = apply_filters( 'the_content', get_the_content() );
 }}}

 The logic of this counting can be observed and checked in the PR from Data
 provider for Unit tests.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/57987#comment:12>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list