Opened 18 years ago
Closed 17 years ago
#4807 closed enhancement (fixed)
Word Count
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 2.6 | Priority: | normal |
Severity: | minor | Version: | 2.3 |
Component: | Administration | Keywords: | has-patch blessed |
Focuses: | Cc: |
Description
Add word count thingummy to the Write Post screen. Should work in Visual view, Code view and tinyMCE-just-plain-off view.
Patch accomplishes this in Firefox, Safari, IE6/7, Opera.
Is it core?
Attachments (6)
Change History (47)
#2
@
18 years ago
-1
I don't really see the point. I mean who cares how many words are in your post? I bet 99% of people don't.
Best left to a plugin IMO.
#3
@
18 years ago
I'm on the fence with this one. While it's cool and I can definitely see the use (and I'd probably pay attention to it when I'm writing a post), I question whether it's really something that a wide range of users will use. But then again, it's unobtrusive enough that I also can't decide if it's plugin material or just a trivial addition to the core.
#6
follow-up:
↓ 7
@
18 years ago
-1.
Really, i don't see why have this in wordpress editor. If i wanna have a word counter and other goodies, I gonna use a real word procesor.
#7
in reply to:
↑ 6
@
18 years ago
Replying to jaroche:
Really, i don't see why have this in wordpress editor. If i wanna have a word counter and other goodies, I gonna use a real word procesor.
That's true. Word count is a small feature of a word processor. If we include word counting, then we're showing favouritism by not also turning it into a mini word processor.
(Oh boy, I wrote 'word processor' twice. Both times, I actually wrote 'WordPress', then had to hit backspace and correct it.) :)
#8
@
18 years ago
- Owner changed from anonymous to mdawaffe
- Status changed from new to assigned
Patch updated.
As an aside, since this is completly JS, the feature can be easily disabled by plugin with the following.
wp_deregister_script( 'word-count' );
(Not a mark for/against the idea, just an FYI.)
#10
@
18 years ago
+1. I see no issues with it being on the write page. Okay, so it's bling, but users notice bling. And given that this is extremely minor bling, I'm for it.
#11
@
18 years ago
-1. Surely plugin territory. I don't see how this is of any interest to 99% of users.
#12
@
18 years ago
Although I -1'd it, I've been testing anyway and there are a couple of bugs with 4807b:
- Write two or more words, word count is immediately out by one.
- Write any amount of text, delete some and continue writing, word count is now very wrong.
Trunk at r6054, Firefox 2.0 on Vista, applies to RTE and non-RTE. Affects WP.com too.
#13
@
18 years ago
-1 for core. The vast majority of people don't care. Blogs are supposed to liberate writers from the draconian word-count restrictions of their print ancestors.
Plugin.
#14
@
18 years ago
-1. It seems like a great idea for a plugin. Most users don't care, and those who do probably won't be satisfied anyways unless the count appears publicly.
#15
@
17 years ago
Can I solve the plugin/core dilemma with the "on the fence" solution?
Surely everyone would be happy with:
+1 for Plugin Distributed With Core, like Dolly. Not active by default.
Obviously, only if the plugin is actually adding things up correctly...
#16
@
17 years ago
+1. I currently use a plugin for this but would love to have it built in. It helps me get a feel for when to stop writing (as I can be wordy). Right now will work for this comment... :-)
#17
@
17 years ago
+1. I'm sure many people would appreciate a word-counter for many different reasons... if they are posting essays that must be a certain length, et cetera.
#18
@
17 years ago
I have a word count script that might be of use. It counts correctly, but I'm still learning JS and I don't know yet how to work around IE's broken event handling. Works great in other browsers.
#19
@
17 years ago
- Keywords needs-patch added; has-patch removed
Changing to needs-patch. With the current patch, the live update count becomes incorrect once any text has been deleted.
#20
@
17 years ago
- Milestone changed from 2.5 to 2.6
-1.
There's enough debate to conclude that the feature is in plugin territory. I can see how it may be useful to some authors but I don't see it as something that most blog authors would find useful. I'm going to recommend closing, in any case it should be bumped to 2.6
#21
@
17 years ago
- Milestone 2.6 deleted
- Resolution set to wontfix
- Status changed from assigned to closed
#22
@
17 years ago
- Milestone set to 2.5.1
- Priority changed from low to normal
- Resolution wontfix deleted
- Status changed from closed to reopened
- Version changed from 2.3 to 2.5
I'm in need of this for 2.5. Could anyone update this patch?
#23
follow-up:
↓ 25
@
17 years ago
- Milestone 2.5.1 deleted
- Resolution set to wontfix
- Status changed from reopened to closed
This was closed as wontfix. If you need this, you could make a plugin for it.
#25
in reply to:
↑ 23
@
17 years ago
Replying to ffemtcj:
This was closed as wontfix. If you need this, you could make a plugin for it.
I would if I could. :(
#26
@
17 years ago
There is a plugin that does word counting already (but not live, just on save) called Word Statistics, and it also shows some readability numbers as well. I use it on 2.5 and it seems to work fine.
#27
follow-up:
↓ 28
@
17 years ago
- Keywords has-patch added; needs-patch 2nd-opinion removed
- Milestone set to 2.5.1
- Priority changed from low to normal
- Resolution wontfix deleted
- Severity changed from trivial to minor
- Status changed from closed to reopened
Adapted the script from 4807b for WordPress 2.5/TinyMCE 3, also changed the counting regexp to make it faster and added re-counting on pressing Backspace.
#30
follow-up:
↓ 31
@
17 years ago
Count reduction by pressing Backspace key doesn't seem to work, and it's counting punctuations as words if they are followed by a space.
#31
in reply to:
↑ 30
@
17 years ago
Replying to michaelpark:
Count reduction by pressing Backspace key doesn't seem to work, and it's counting punctuations as words if they are followed by a space.
It re-counts on pressing a key after pressing backspace, so if you delete something by holding down backspace, it will re-count when you start typing again. Same as when typing: it increases the count after pressing the space bar, not when it's pressed.
Yes, special characters/punctuation is counted as a word if it's separate from the end of the previous word. So "Hello!" would be 1 word, but "Hello !" would be 2 words. As far as I can tell all word counting works this way (is separate punctuation considered words? Perhaps non-verbal form of expression? Is this a word " :-) "?).
#32
@
17 years ago
No, it's not a word. Words should be consist of only alphabets -- no numbers or punctuations.
#33
@
17 years ago
OK, fixed. Now it only counts words consisting of letters or mixed letters/numbers, no numbers only or any punctuation/special characters. Still supports all extended ASCII characters, like è, é, ë, ñ, ü, etc.
#35
in reply to:
↑ 34
@
17 years ago
Replying to michaelpark:
Hmmm, I think it's still counting punctuations as words.
Now it strips all characters except the letters and spaces before counting. While typing, it still increases the count on every pressing of the spacebar (as it did before), so the count would go higher if typing numbers for example, but then it's corrected when pressing Enter or after pressing Backspace.
It's not practical to re-count on every pressing of the spacebar as in large posts with a lot of HTML tags on slower computers it would interfere with the speed of typing.
The alternative would be to disable the increase of the count on pressing the spacebar and to update it only on Enter and after Backspace (at the end of each paragraph).
Also tried to make it remember the position of the last full re-count (user pressed Enter), then count only the extra words after that on each pressing of the spacebar (the current paragraph). That would make it more accurate while typing, but if the user goes back and deletes some text, then continues typing without triggering full re-count, it still would be wrong. Can put this back in.
#36
@
17 years ago
That's a good idea actually. I can live with having to press enter.
Thanks again!
#38
@
17 years ago
Simplified it a bit: now counts only on Enter, or after Backspace or Delete keys are pressed. The word count is updated less frequently but is always right.
Try the ideas section to pledge your idea, Go here It's trivial if we need it or not, thats why I am changing it to "low" however it is a good idea.