processwire-issues icon indicating copy to clipboard operation
processwire-issues copied to clipboard

Docs typos

Open adrianbj opened this issue 6 years ago • 49 comments

Hopefully we can all make use of this issue to add typos as we find them rather than creating new issues for each one.

  1. https://processwire.com/api/ref/fieldgroup/has-field/ Does this fieldgroup have~~ing~~ the given field?

  2. https://processwire.com/api/ref/config/version/ Check if current ProcessWire version is equal to or newer than given versi**~~n~~on**

adrianbj avatar Jan 21 '19 22:01 adrianbj

Not a typo exactly but the Template::hasField() method has no arguments description: https://processwire.com/api/ref/template/has-field/

Toutouwai avatar Jan 21 '19 22:01 Toutouwai

Thanks I have pushed the suggested fixes.

ryancramerdesign avatar Feb 04 '19 20:02 ryancramerdesign

Pageimage.php, line 50: file -> File Pageimage.php, line 1656: please add @since 3.0.126 for render() method Pageimages.php, line 225: please add @since 3.0.126 for render() method Pageimage.php, line 1657: and or -> and/or Sanitizer.php, line 24: intances -> instances Sanitizer.php, line 75: example -> example, Sanitizer.php, line 86: ta -> a

matjazpotocnik avatar Feb 05 '19 06:02 matjazpotocnik

In ProcessPageList.module(/wire/modules/Process/ProcessPageList/ProcessPageList.module): hierarchal should be hierarchical

  • line: 6
  • line: 41

gmclelland avatar Feb 15 '19 21:02 gmclelland

In ProcessPageList.module(/wire/modules/Process/ProcessPageList/ProcessPageList.module): classs should be class line: 327

gmclelland avatar Feb 20 '19 20:02 gmclelland

https://processwire.com/blog/posts/text-blocks/

'start_reqirements'

jlahijani avatar Feb 23 '19 01:02 jlahijani

double negative on this page: https://processwire.com/api/ref/sanitizer/

Sanitize input string as multi-line text without no HTML tags

jlahijani avatar Mar 06 '19 02:03 jlahijani

Typo in $database API example: https://processwire.com/api/ref/wire-database-backup/

The very first example, instead of $database->backup(); looks like should be: $database->backups();

Source: https://processwire.com/talk/topic/20967-not-sure-where-to-report-code-sample-typos-in-the-api-docs/

szabeszg avatar Mar 06 '19 12:03 szabeszg

@szabeszg @jlahijani Thanks, fixed.

ryancramerdesign avatar Mar 08 '19 15:03 ryancramerdesign

module.php: "You may implement also implement this method as hookable, ..." double implement

matjazpotocnik avatar Mar 13 '19 14:03 matjazpotocnik

wire\modules\AdminTheme\AdminThemeUikit\config.php

"Chose option B if you are having any trouble achieving intended Inputfield column widths."

Change Chose to Choose.

jlahijani avatar Mar 21 '19 15:03 jlahijani

wire\core\WireArray.php

"Property or properties to retrieve, or callable function that shuld receive items."

shuld -> should

jlahijani avatar Mar 23 '19 17:03 jlahijani

wire/core/Wire.php

Line 1618: $this->wire('widgets', $widgets');

should be: $this->wire('widgets', $widgets);

gadgetto avatar Apr 01 '19 13:04 gadgetto

A double semicolon in line 289 in ProcessPageAdd.module: $parentTemplates = new TemplatesArray();;

In case you didn't see: typo in Pageimage.php line 1558 https://github.com/processwire/processwire/pull/139/commits/a434b1be0089fa4787cb62caeb2d27c1f3bb3dff

matjazpotocnik avatar Apr 01 '19 16:04 matjazpotocnik

WireArray.php "Flags for PHP sort functdions" -> functions

matjazpotocnik avatar Apr 02 '19 18:04 matjazpotocnik

ProcessModule.module here and here

"This URL may be be accessed directly" should be "This URL may not be accessed directly".

Toutouwai avatar Apr 04 '19 03:04 Toutouwai

Not a typo, but there appears to be no links to this important documentation page: https://processwire.com/api/ref/paths/ The URL structure implies that it should be linked to from https://processwire.com/api/ref/ Are there other similar pages under https://processwire.com/api/ref/ that are not linked to from the parent page but should be?

Toutouwai avatar Apr 04 '19 04:04 Toutouwai

Another unlinked section of the API docs: https://processwire.com/api/ref/pages-names/

Toutouwai avatar Apr 07 '19 04:04 Toutouwai

@Toutouwai These are dynamically generated doc pages from the ProcessWireAPI module that go out and look for the class and then generate a doc page for it on the fly. The list you see a /api/ref/ is just a small curated list that I've picked out as being the most useful/important parts of the public API, which is probably only about 1/10th of the total number of classes you could generate documentation for from this endpoint/module. Other classes are linked where relevant as argument or return values. If you think the ones you mentioned need more exposure, I can always include them in the curated list index, but I also want to be careful about having too much info up front.

ryancramerdesign avatar Apr 09 '19 10:04 ryancramerdesign

I personally would add https://processwire.com/api/ref/paths/ since it's common to use in templates, even (or especially) for beginners. https://processwire.com/api/ref/pages-names/ is from my point of view more developer oriented.

matjazpotocnik avatar Apr 09 '19 10:04 matjazpotocnik

@matjazpotocnik @Toutouwai I think you guys are right about Paths — I've added the Paths class to the main index (and also as $urls API var). for PagesNames, I've not added it to the main index but it does seem like it's got potential usefulness in the public API (even if occasional), so have made the $pages->names() method part of the public API so that the class can be navigated to (as the return value for that method) or it can be found from the search.

ryancramerdesign avatar Apr 09 '19 15:04 ryancramerdesign

Again, not really a typo, but I think that $mail needs references to all the methods that are available to WireMail. If you look at the docs to $mail you don't see anything like toName(), fromName(), etc.

I think newbies won't know to also check the WireMail() docs. I think it's also really important to explain why $m = new WireMail(); is a bad idea unless you know what you are doing - ie it breaks modules that extend WireMail.

adrianbj avatar Apr 09 '19 17:04 adrianbj

The list you see a /api/ref/ is just a small curated list that I've picked out as being the most useful/important parts of the public API, which is probably only about 1/10th of the total number of classes you could generate documentation for from this endpoint/module.

Personally I'm in favour of listing all documentation pages that exist. To avoid clutter and give the most important pages priority the other currently unlisted pages could be contained in a collapsed Other/Advanced/Kitchen Sink section (whatever naming you think best).

Besides the fact that I myself would refer to these pages I think it adds credibility to the PW project to have full and comprehensive documentation on display.

Toutouwai avatar Apr 09 '19 23:04 Toutouwai

In PageimageVariations.php in count(): @param array $options See options for find() emthod

matjazpotocnik avatar Oct 19 '19 10:10 matjazpotocnik

In Inputfield.php, line 1280, ragument -> argument

matjazpotocnik avatar Oct 29 '19 07:10 matjazpotocnik

In wire/core/Exceptions.php, line 43, one "there is" too many

matjazpotocnik avatar Nov 08 '19 16:11 matjazpotocnik

In WireInput.php, line 322, sanitizedd

chriswthomson avatar Dec 06 '19 19:12 chriswthomson

In PageArray.php, line 78, Template mehod

chriswthomson avatar Dec 18 '19 14:12 chriswthomson

In Module.php, I think "called" should be "cannot":

If the install() method determines that the module called be installed for some reason, it should throw a `WireException.`

Toutouwai avatar Dec 19 '19 20:12 Toutouwai

In ProCache 4: "When in cahce debug mode" (the word 'cache' is misspelled).

jlahijani avatar Aug 09 '20 20:08 jlahijani