The example in Settings API documentation uses admin_init
and admin_menu
for registering custom settings and admin pages. https://developer.wordpress.org/plugins/settings/custom-settings-page/
There’s also an old Codex entry on actions typically run on front and back end requests, which can help pick a suitable action hook. https://codex.wordpress.org/Plugin_API/Action_Reference
I also highly recommend the excellent old Q&A about instantiating classes in WP. Best way to initiate a class in a WP plugin?
Related Posts:
- Should all plugins be encapsulated in a Class?
- How do I extend one plugin I’m writing with another I’m writing using classes?
- How to Loop Plugin Option Field Set?
- Saving Plugin settings to the database
- Check if a class exists within a method
- Show admin notice on incorrect value on form field
- Basic Object Oriented plugin question
- Using plugin functions/methods within templates
- Why is my custom post type not being activated on plug-in activation?
- Built a second plugin but it overwrote the first one
- WordPress Custom Hook with Class method
- WordPress plugin blog creation
- Get post content inside plugin class method
- Creating a register settings class that supports extended classes
- Autoloading a PHP class – working outside, but not inside WordPress plugin
- private functions in plugins
- Strict Standards: Non-static method in sidebar generator
- Function not being called on form submit, only blank admin-post.php page
- How can I use WordPress functions in my stylesheet?
- Plugin or mod for wordpress to make content publication SUPER easy
- Cropping, Re-sizing and Saving images from one folder to another folder in wordpress
- scheduled event not getting executed
- How can I include a setting that has a variable number of values in a settings page using register_setting?
- Stop the form of beign submitted on “Save changes” custom option page
- Settings API – input always updates over validation
- Creating search filter through plugin
- How to edit/delete single row items in a table on my own menu page
- Displaying Gravity Form data on WordPress page [closed]
- How to trigger $_GET request within admin plugin page?
- Wp favorite posts get user favorites in profile using buddypress [closed]
- How to ‘clone’ a wp plugin to make small changes
- add mediaelement.js plugins into WordPress video player control bar
- Preferred way of cacheing a value in php
- Edit Yoast SEO breadcrumbs output [closed]
- Adding a slider captcha to the comment system
- Query all customers/users and check for duplicate information
- WordPress function not being called from jQuery method
- CMB2 toolkit: Compare 2 Dates and validate the Time
- PHP Warning: call_user_func_array() expects parameter 1 to be a valid callback Error without any function name
- Adapt PHP form action for WordPress?
- Individual testimonial taxonomy not displaying (white screen)
- Using TinyMCE in plugin?
- Media Upload Tab reload and change $_GET
- Use wordpress plugin in codeigniter
- How to Loop Through all Posts and Count Attachments using Get Media Attachments
- Only allowing some emails to create an account [closed]
- Basic function call on init failing
- Get ‘Headers already sent’ error for the plugin I am creating when I try to login
- Return multiple values in a shortcode attribute
- get specific value of a array | PHP
- Creating a functionality plugin to edit seriously simple podcasting
- Programatically upload a file to be stored inside blob field in database, NOT on filesystem
- Make plugin php file called directly aware of WordPress?
- Creating an admin meta box to save post as pending
- Next Previous Post in wordpress with previous / next link with title?
- WordPress truncate posts question (plugin related)
- WordPress Post HTML after Posting
- Settings options not showing up on Sub Menu page in WordPress plugin
- Cannot Access Console
- Plugin error after installation
- woocommerce remove coupon link does not work
- Use a hook or filter, or overwrite this Gamipress function?
- Plugin or ways to limit number of users logging in the website,
- Replace old theme that understand old css (vcex_icon_box css_animation)
- How to insert datas in the table on wordpress?
- WP Ajax DB issues
- ACF checkbox return format based on page
- How to get database connection details without longing to cpanel in WordPress?
- The Build menu theme is frozen with the wordpress theme
- Does anyone know why my SEO and title become one?
- How to translate wordpress blog to other languages?
- How to translate to spanish wordpress hardcoded content/files?
- How to get a post views count using ‘WordPress popular posts’ plugin
- Get Shortcode output to database for static post_content
- strtotime not working
- Prefix WordPress Taxonomy Tags With Hashtag Symbol Like Twitter
- How To Toggle User_Meta in frontend in a form using PHP
- Change Woo Custom Endpoint Titles from a Plugin
- Change custom rewrite rule when permalink is updated/changed
- Optimized PHP & WordPress settings for speed/performance?
- Speeding up WordPress on a Local Network
- How can I store user preferences in WordPress and retreive them later?
- Any method to make specific widget for every post and page?
- How to add php plugin code in theme
- how change my menu on submenu
- Plugin debugging with errors in activation routine
- Embed Javascript code to registered users only
- Find all strings between an enclosing shortcode
- How to set up php,javascript and css to allow for our finished product to be displayed within a page?
- W3 Total Cache Can’t Really Detect Things
- Hyperlink to execute PHP
- How to get site homepage from plugin?
- How do I add php to all links automatically?
- Vote It Up Plugin – Add ascending numbers to MostVotedAllTime Chart Function
- How to fix vanilla comments extra iframe space
- Meta Box plugin image_advanced not showing up on frontend
- Creating Features List in WordPress Post
- PHP Creating a formula from mysql db values and db stored math operator
- WordPress Convert queries to slashes using function.php
- plugin doesn’t retrieve data from database