Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Patch widget options #16

Open
johnbillion opened this issue Apr 7, 2018 · 1 comment
Open

Patch widget options #16

johnbillion opened this issue Apr 7, 2018 · 1 comment

Comments

@johnbillion
Copy link
Contributor

The options for a widget are stored as a serialised array. There's no way of patching a field in a widget's options using wp widget update.

Possible syntax:

wp widget patch <widget-id> <field> <key-path>... [<value>]

Example usage:

wp widget patch archives-3 options title "My Site Archives"

@schlessera
Copy link
Member

For consistency, we should use the same syntax as we do with the other patch commands:

wp widget patch <action> <widget-id> <field> <key-path>... [<value>]

where <action> is one of insert, update, delete.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants