WP Word Count

Descrizione

WP Word Count tells you exactly how many words you’ve written on your site with statistics by month and author.

New in Version 3.2.0: Reading Time
WP Word Count now comes with built in reading time statistics for each post and page of your site. Find out how many hours of content you’ve written or let readers know how long your articles are. You can include reading time at the top of each of your posts automatically or use a shortcode.

FEATURES

  • Quickly see how many posts and pages you’ve created and how many total words they add up to.
  • View and display estimated reading times for each piece of content on your site.
  • Support for custom post types so you can monitor word counts from content created by your themes and plugins.
  • View your writing output for each month broken down by post type.
  • See all of your site author’s word counts with breakdowns by post type.

WP WORD COUNT PRO

Upgrade to WP Word Count Pro and get additional features to help you understand and analyze the amount of content you are producing for your site:

  • Control which post types and statuses you see in your statistics through custom “Settings” options.
  • Get detailed breakdowns of your monthly writing output by day, author, post type, category, tag and more.
  • View individual author details with information beyond just word count totals.
  • See expanded post details with revision history, site rankings and more.
  • Motivate yourself with the built-in achievement system to write more and increase your site’s content.
  • View charts and graphs for better data visualization and understanding.

You can learn more about WP Word Count Pro at wpwordcount.com

Screenshot

  • WP Word Count
  • Monthly Statistics
  • Author Statistics
  • Reading Time Settings

Installazione

  1. Upload wp-word-count to the /wp-content/plugins/ directory
  2. Activate the plugin through the ‘Plugins’ menu in WordPress
  3. WP Word Count can be accessed via the menu of the WordPress Admin.

FAQ

How do the WP Word Count Shortcodes work?

There are two shortcodes available:

  • [wp-word-count] will display the number of words on any page or post.
  • [wp-word-count-reading-time] will display the reading time of words on any page or post.

Every WP Word Count shortcode can be extended with “before” and “after” attributes to add text or HTML before and after the result.

Example: [wp-word-count before=”This post has” after=” total words.”]

Recensioni

27 Dicembre 2023
This plugin is a bit over the top for my needs. I just want a little box to display the number of words in the post (under all the other little boxes on the right side that has Revisions, Tags, Categories, underneath those). Placed this in my functions.php and it does the trick. /* START word count post */ function add_word_count_meta_box() { add_meta_box('word_count_meta_box', 'Word Count', 'word_count_callback', 'post', 'side'); } function word_count_callback($post) { // We'll use JavaScript to update this live echo '<div id="word-count-wrapper">Word Count: <span id="word-count">0</span></div>'; ?> <script type="text/javascript"> jQuery(document).ready(function($) { var updateWordCount = function() { var content; if (window.tinymce) { var editor = tinymce.get('content'); if (editor && editor instanceof tinymce.Editor) { content = editor.getContent({ format: 'text' }); } else { content = $('#content').val(); } } else { content = $('#content').val(); } var wordCount = content.split(/\s+/).filter(function(word) { return word.length > 0; }).length; $('#word-count').text(wordCount); }; // For classic editor $('#content').on('input', updateWordCount); // For block editor if (window.wp && wp.data && wp.data.subscribe) { var checkForWordCountUpdate = function() { var content = wp.data.select('core/editor').getEditedPostContent(); var wordCount = content.split(/\s+/).filter(function(word) { return word.length > 0; }).length; $('#word-count').text(wordCount); }; wp.data.subscribe(checkForWordCountUpdate); } // Initial count on page load updateWordCount(); }); </script> <?php } add_action('add_meta_boxes', 'add_word_count_meta_box'); /* END word count post */ The code provided for the WordPress word count functionality defines a word as any sequence of characters separated by whitespace. Specifically, this is how the word count is calculated: Splitting the Text: The split(/\s+/) function in JavaScript is used to split the content of the post into an array of substrings using a regular expression. The \s+ pattern matches any sequence of whitespace characters (spaces, tabs, newlines, etc.). Filtering Non-Empty Words: The filter(function(word) { return word.length > 0; }) part of the code filters out any empty strings from the array. This is important because the split function can create empty strings if there are spaces at the beginning or end of the text, or multiple spaces in a row. Counting Words: The length property of the resulting array (after splitting and filtering) gives the number of words. Each element of the array represents a word. With this code, a word is any non-empty string of characters that is separated from other words by one or more whitespace characters. This is a common and general way to count words, but it does have limitations. For example, it doesn't account for words joined by hyphens (like "long-term") or apostrophes (like "don't"), which are typically counted as single words. Additionally, numbers or strings of punctuation without spaces would also be counted as words. This approach is suitable for a general word count feature, but for more advanced or specific word counting rules, the code would need to be adjusted accordingly.
11 Novembre 2023
Not good at all, no functionality at all, and a total waste of time. you are better off using the opensource WordPress word count providedof course, you might get the bells and whistles if you pay, but I would rather use my own FREE code snippets
23 Ottobre 2019 1 risposta
not all words count. unusable
25 Febbraio 2019
Hi, I'm so impressed with this amazing plugin. However, for Chinese bloggers we don't separate our words with spaces. What we call the word number usually means the character number. So could you please add a feature that can calculate the character numbers (ignore space and punctuation) of all my post? Much thx!
5 Febbraio 2018
We use CornerStone / Pro from Themeco and it seems like the process is having a hard time finding out what is a word and what is not. WP Word Count's result is ~1500 words for a ~4500 words page. We manually compared to make sure.
Leggi tutte le recensioni di 13

Contributi e sviluppo

“WP Word Count” è un software open source. Le persone che hanno contribuito allo sviluppo di questo plugin sono indicate di seguito.

Collaboratori

“WP Word Count” è stato tradotto in 2 lingue. Grazie ai traduttori per i loro contributi.

Traduci “WP Word Count” nella tua lingua.

Ti interessa lo sviluppo?

Esplora il Codice segui il Repository SVN iscriviti al Log delle Modifiche. Puoi farlo tramite RSS con un lettore di feed.

Changelog (registro delle modifiche)

3.2.4 – 1 Apr 2023

  • Tested up to WordPress 6.2.0
  • XSS issues fixed

3.2.3 – 6 Oct 2021

  • Tested up to WordPress 5.8.1
  • We’ve been a bit quiet (sorry!), but busy behind the scenes! Get ready for some new features ready in Q4 2021!

3.2.2 – 8 Sept 2020

  • Tested up to WordPress 5.5.1

3.2.1 – 2 June 2020

  • Tested up to WordPress 5.4.1
  • Updated plugin details

3.2.0

  • New “Reading Time” statistic throughout the plugin.
  • Added support for Gravatar/User Profile Images.

3.1.0

  • New calculation options for sites with extremely large amounts of content.
  • Menu changes.

3.0.2

  • Interface changes.

3.0.1

  • Interface changes and bug fixes.

3.0.0

  • You can calculate your word counts any time you wish via the “Calculate” tab. This should help alleviate problems with plugin activation/updating on servers with limited resources.
  • Automatically excluding common WordPress post types: Custom CSS, Navigation Menu Items.
  • Support for Scheduled Posts.
  • Support for Thrive Content Builder.
  • Interface changes.
  • General bug fixes.