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
- (FES EDD) New vendor submission page is blank
- Most efficient way to use classes to create admin pages using Settings API
- Merging Two menus in the backend into one menu
- Basic Object Oriented plugin question
- WordPress plugin/theme or other wayout to create portable pages?
- Using plugin functions/methods within templates
- php page not found for plugin options menu
- Delete mobile menu button [closed]
- html generated by theme exist but doesnt appear in browser
- Dynamic admin submenu
- Center and hide overflow of WP toolbar custom links
- WordPress page and plugin list using sql query
- Create page from plugin, but have it completely hidden
- How to remove admin main menu name repetition
- 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 to add subcategories to the blogroll?
- 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
- Object method calling for global $wpdb in header.php
- Proper way to replace the_content only for pages created by custom plugin
- Add menu page issues (permissions & position)
- How to use my menu PHP code as sidebar?
- Redirect to another page using contact form 7? [closed]
- Display Custom Field Value on Admin Page Column
- Would Gutenberg be considered a PlugIn?
- I need help locating a URL that is on my site map, but that I can’t find in my WordPress dashboard
- Show author on every sub-page
- Why is my custom post type not being activated on plug-in activation?
- How to have sample page for each new register users in a membership website
- One sub site is slow while all others load fine, same theme & plugins [closed]
- How to prevent PHP fatal error if plugin hasn’t been enabled and a method is called in theme file?
- Hide a Menu Item on Login
- How to get menu location in wp_update_nav_menu hook
- How to create a page with links to other pages that include image and excerpt?
- PHP script from functions php is loaded via admin-ajax to div…and the result is 0, not the desired content
- Thesis 2 custom Page
- Making my plugin create a page?
- Add Content to Content()
- Simulating a wp page – wp page load sequence
- Progmatically adding menu links to the default (Top) or Footer menu
- get_option / wp_localize_script Not Working in OOP Plug In
- Built a second plugin but it overwrote the first one
- $pages = get_pages(‘child_of=’.$post->ID); Why arguments are concatenated?
- How to create wordpress page that lets users create their own quiz? [closed]
- profile_update hook doesn’t works inside a class
- Huge number of 404 pages getting spawned
- WordPress Object Oriented plugin development [closed]
- How to access OOP plugin function inside themes or other plugin
- Changing location of “About me” section
- 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
- How to create plugin auto create page wordpress?
- Custom form not showing in correct place on page
- Change website directory safely to add a static page on startup
- How can I add a fixed vertical menu to my site? [closed]
- Price comparison table based on Custom Post Type?
- 2 wordpress site same database
- Hook on creating a menu entry?
- Use jQuery Datepicker code from plugin
- How to force load a page in plugin?
- How to dynamically change spots of text in custom page?
- Dropdown menu on click change
- navigation among single posts
- Custom page in plugin visible in menu
- How do i specify a url to which to redirect the user after he logs out from facebook?
- Adding a pagenavi to function for displaying bookmarks
- 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
- Pasting this PHP breaks my page. Why?
- Modify pages widget and make a plugin?
- How do I create pages within a WordPress post?
- I cannot include a file in my plugin settings page
- Gantry Framework: new page loads homepage content instead of page content
- Woocommerce checkout page broken when set as a checkout in woocommerce settings [closed]
- Elementor Combined all Sections into 1 Text Editor
- Custom plugin places html head content in body
- Button and Countdown overlapping mobile menu
- Pass PHP variable to javascript
- How to permanently show Word Counter on Create/Edit Page. WordPress5.9.3
- Displaying page content from plugin, inside exising empty WP page
- Slideout submenu in mobile
- Oops! That page can’t be found
- Copy/paste local images not working in WordPress
- Use get_pages() before another plugin modifies it
- how to show all posts of each category in pages
- Elementor: How to design Dropdown Select Box Navigation page like Chegg
- WordPress Custom Hook with Class method