[wp-trac] [WordPress Trac] #45812: WP_Customize_Setting sanitize_callback is given 2 parameters; PHP warning and validation fail
WordPress Trac
noreply at wordpress.org
Wed Jan 2 18:34:13 UTC 2019
#45812: WP_Customize_Setting sanitize_callback is given 2 parameters; PHP warning
and validation fail
--------------------------+------------------------------
Reporter: marclarr | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Customize | Version: 5.0.2
Severity: normal | Resolution:
Keywords: | Focuses:
--------------------------+------------------------------
Comment (by marclarr):
Hi @joyously, You are correct it's the control object that is sent as a
second parameter, my bad. Many/most sanitation functions only accept one
parameter. Also, I have worked with the customize API in the past and
didn't run into this issue before using other sanitize callback function
like e.g. sanitize_hex_color. It appears I'm doing everything correctly,
yet I receive errors.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/45812#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list