[wp-trac] [WordPress Trac] #55942: Add a "value type" parameter to get_option() and get_metadata()
WordPress Trac
noreply at wordpress.org
Sun Apr 30 19:44:24 UTC 2023
#55942: Add a "value type" parameter to get_option() and get_metadata()
-------------------------------------------------+-------------------------
Reporter: azaozz | Owner: (none)
Type: enhancement | Status: new
Priority: normal | Milestone: 6.3
Component: Options, Meta APIs | Version:
Severity: normal | Resolution:
Keywords: has-patch has-unit-tests needs- | Focuses:
testing | performance
-------------------------------------------------+-------------------------
Comment (by azaozz):
@rjasdfiii @Otto42 Thanks for the explanation of the MySQL `DECIMAL`
format. As @Otto42 mentions I don't think there is a column in any of the
default WP tables that is using or may benefit from it.
There are several that are `LONGTEXT`, like option and meta values, but
they are designed to hold different types of data. Hence the use of PHP's
`serialize()` and the need of this ticket to maker it possible to retrieve
strict data types.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/55942#comment:59>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list