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

Added composer file and some enhancements #18

Closed
wants to merge 12 commits into from

Conversation

rahal
Copy link

@rahal rahal commented Nov 17, 2022

First of all, big thanks for the library (I'm using it in my plugin "Mail Control" - soon to be published in wordpress plugins repo).
I added a composer file to allow importing the library with composer.
And also updated the contructor to accept an array of options and to define constants using the form SECTION_NAME_FIELD_NAME (if not already defined).
Let me know what you think.
Thanks again

trigger action settings_ready when settings are initiated
Added Composer install and usage
Added support to show_if : a simple callback to hide settings
…anitization method is provided in the field config.

Older sanitize_fields used to loop over all sections and fields to get retrieve the callback, which could be problematic if two or more fields have the same ID.
Now sanitize_fields will receive the section_id and will rely on get_field_config($section_id, $field_slug) to retrieve the fields config and sanitize according to
Added sanitize for email and url types
- Added support for (generated) content field
- Added support for query attribute to generate options for select type
Introduced settings_name, to trigger action settings_ready_{settings_name} instead of settings_ready
@rahal
Copy link
Author

rahal commented May 7, 2023

Hello,

I submitted a pull request to this project a while back, but unfortunately, I haven't received any feedback. In the meantime, I've decided to fork the project and maintain it myself, as it seems the original project has become inactive.

I wanted to let you know that I'm already using this work in two free WordPress plugins, Mail Control (https://wordpress.org/plugins/mail-control/) and AIIFY (https://wordpress.org/plugins/aiify/). Additionally, I plan to add the library to Packagist for better ease of use.

Given my intention to maintain the fork, I will be closing this pull request. However, I'd like to extend an invitation for you to collaborate with me on the forked project. I'd be happy to discuss any concerns or feedback you may have.

Thank you for your work on this project, and I hope that we can work together to continue improving it.

@rahal rahal closed this May 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant