#28467 closed defect (bug) (fixed)
Improved inline docs for set_transient & set_site_transient in options.php
Reported by: | edwin-at-studiojoyo.com | Owned by: | DrewAPicture |
---|---|---|---|
Milestone: | 4.0 | Priority: | normal |
Severity: | normal | Version: | 4.0 |
Component: | Options, Meta APIs | Keywords: | has-patch dev-feedback |
Focuses: | docs | Cc: |
Description (last modified by )
The maximal length for the string $transient is not defined in the inline documentation. This patch adds this for set_transient and set_site_transient.
In the Codex (#15058) there is already a discussion about this topic; however, that is about validation. And as this discussion is still ongoing, this addition to the inline documentation is helpful to the developers and users.
Attachments (3)
Change History (10)
#4
@
10 years ago
The maximal length is a requirement, as the transient name will fail if maximal length is exceeded. Thus, "should" must be changed to "must":
MUST: This word, or the terms "REQUIRED" or "SHALL", mean that the definition is an absolute requirement of the specification. (see http://www.ietf.org/rfc/rfc2119.txt).
Will attach newly corrected patch.
As an addition, the Codex (http://codex.wordpress.org/Function_Reference/set_transient and http://codex.wordpress.org/Function_Reference/set_site_transient) must also use the word "must", in stead of "should".
Is the 45 character limit a suggestion or a requirement? If it's a requirement, we should use "must" rather than "should".