You have mix up in static and non-static usage. Your style is non-static, but your methods are declared as such. If you enable WP_DEBUG
mode you’ll see following errors:
Notice: Undefined variable: this
Warning: call_user_func_array() expects parameter 1 to be a valid callback, first array member is not a valid class name or object
This happens because static method doesn’t “know” what $this
refers to, since static isn’t tied to specific instance of the class.
Simply declare your methods as public
rather than public static
for this code organization.
Related Posts:
- Wondering what these multi-colored extra pages are?
- Changing page URL and connect newsletter to MailChip
- Page Contents showing in Footer Area
- How to disable users to view Other pages
- Redirect url in plugin to somewhere else?
- Plugin: Custom menu item problem
- Get plugin_dir_url() from one level deep within plugin
- Check if add_menu_page exists or not
- Add custom menu item type
- Create page when plugin is activated
- How to call “page specific menu items” in template [closed]
- How can I show drafts in wp_dropdown_pages list?
- WP-PageNavi plugin doesn’t work with multiple pages of search results
- Trying to get logged-in user data inside php class
- How to make a plugin auto-add item to nav menu
- Check if a class exists within a method
- Is there a way to lock certain pages from being edited by anyone other then the admin?
- Replace existing pages with new pages, keep menu links
- Multiple navigation menus to a location?
- Making menu link open in new tab?
- Show a special message for private page?
- How can plugins have their own pages?
- Add a plugin before main container
- Calling custom plugin class methods from a template
- How to make a customize role and view a specific plugins base on that role?
- plugin class inheritance. cannot change variable
- Easiest way to add dropdown to a page
- WordPress web pages keep getting deleted (moved into the trash) by themselves
- Run plugins only on certain pages
- (FES EDD) New vendor submission page is blank
- Merging Two menus in the backend into one menu
- Using plugin functions/methods within templates
- Delete mobile menu button [closed]
- Dynamic admin submenu
- How to handle cookies from a WordPress plugin on a cached page?
- accessing parent variables in child construct without executing action in parent
- Custom Permalink Plugin and Current Page/Ancestor in Menus
- How do I write an inventory list plugin that creates dynamic details pages?
- wp-custom-menu filter removes the current_page_item class
- Can I allow certain people to add/edit pages within a parent?
- add_action does not call the function
- Redirect to another page using contact form 7? [closed]
- Display Custom Field Value on Admin Page Column
- How to prevent PHP fatal error if plugin hasn’t been enabled and a method is called in theme file?
- Thesis 2 custom Page
- Simulating a wp page – wp page load sequence
- profile_update hook doesn’t works inside a class
- Need to revert to an older version of wordpress
- Plugin: Hooking up classes that have their own hooks
- Get post content from outside the loop with plugin shortcode usability
- WordPress Custom Menu Admin helper plugin
- Custom form not showing in correct place on page
- 2 wordpress site same database
- Use jQuery Datepicker code from plugin
- How to force load a page in plugin?
- Dropdown menu on click change
- How do i specify a url to which to redirect the user after he logs out from facebook?
- Is there a syntax highlighting plugin for HTML View? [duplicate]
- What is the best way to make a custom page from a plugin?
- Setting text widget to one page only
- I cannot include a file in my plugin settings page
- Gantry Framework: new page loads homepage content instead of page content
- How to permanently show Word Counter on Create/Edit Page. WordPress5.9.3
- Displaying page content from plugin, inside exising empty WP page
- Oops! That page can’t be found
- Copy/paste local images not working in WordPress
- Elementor: How to design Dropdown Select Box Navigation page like Chegg
- FPDF for creating pdf diplomas
- Adding LOAD MORE on a page
- What plugin would make this happen? If is the theme
- WordPress site hamburger menu toggle not working
- How to allow URL with filename & extension in wordpress?
- Scroll to ID broken in main menu
- Get post content inside plugin class method
- Enabling plugin on specific pages and subpages
- jquery plugin won’t fire when hamburger class element clicked
- Python in WordPress – A “Hello World” implementation
- How to access classes in theme of a plugin?
- Sub Categories in drop down menu
- Wordress admin page is fetching error You do not have sufficient permissions to access this page.
- Admin page and admin menu. Permissions plugin
- Options page textarea to populate custom post select field
- WordPress menu and plugin installation problem
- Power Menus plugin destroys menu after adding new item
- Best way to create member pages for a lab website? [closed]
- Creating a page that does not show up in the frontend navigation bar
- Fatal error when accessing Pages in WP admin (and problems editing any pages)
- add_media_page function not creating submenu
- How can I pass value to function in add_menu_page?
- Why function hooked using object are executing at all time?
- Create a blank admin page from plugin
- Multiple Plugins Interacting with Menu
- private functions in plugins
- How to make only selected posts appear on a selected wordpress page
- How do I add custom fields to the “Edit page” admin screen?
- Strict Standards: Non-static method in sidebar generator
- How to make horizontal scrolling menu [closed]
- Function not being called on form submit, only blank admin-post.php page
- WordPress Plugin and other pages not opening
- Set the Social Icon Size in footer