How are you invoking ngob_sitelist_slug
?
I’m gonna guess that you are doing something like $my_class = new ngob_sitelist_slug;
. Doing it this way would require that your class have a constructor. if it doesn’t, you’ll get an error.
You could still call your class methods statically:
$my_thing = ngob_sitelist_slug::my_method();
Though technically you should add the static
keyword to your methods in this case.
Also I see that in your case you are using $this, so you really need a constructor.
EDIT:
I now realize you do have a constructor – albeit a deprecated one.
Related Posts:
- What is the function to get plugin base url in multisite?
- Redirect to another page using contact form 7? [closed]
- Making my plugin multi-site compatible
- Customizing subject in comment notification e-mails
- Common functionality between my own plugins
- How to Loop Plugin Option Field Set?
- How to handel multiple checkbox field in the admin settings page with Settings API
- wp_insert_user – how to send verification email before logging in
- Editor access to plugin settings
- How to assign user a role if none is present when logging in
- How do I add a widget programmatically to a newly created site (WPMU) within a plugin?
- Saving Plugin settings to the database
- Shortcode display outside the div
- Execute a function using ajax
- WordPress network: set themes and plugins for new blog
- Use functionality of 2 wordpress plugins
- Fatal error: Class not found in
- Extend Elementor Archive Posts widget with a custom skin in order to show multiple badges
- HELP: Integrating WP with raw PHP code once published button is hit
- Override the core function locate_template
- Can wp_script_is used in pluginA check if a script is being enqueued/registered from pluginB?
- I would like to use create a function in my custom plugin to tell WP to use a different header
- Is it possible to set up multistore in Woocommerce? [closed]
- The Point of Using apply_filters()
- How to get variables from fucntion.php to my plugin files
- How to include code into functions.php file via a plugin
- How to define WordPress plugin shortcode globally for multisite?
- WordPress Plugin Page is Loading in Admin Content Container Instead of Separate Page
- How to write a plugin to add users to a mail list
- Edit Yoast SEO breadcrumbs output [closed]
- Display post lists in 2nd paragraph
- Using a post-signup hook to get user details
- Show function to super admin
- creating html reusable blocks via shortcodes
- WordPress get_avatar function not correct working
- Which file of wordpress manage plugins functionalities?
- Difference and examples of esc_attr__() and esc_attr_e()
- List the authors that have written posts in a category
- Certain functions are undefined when called form mu-plugins
- Check if variable is set in filter
- WordPress Multisite: Programmatically Activate / Deactivate a Plugin of a Specific Blog
- Shortcode Attributes to Return different $_POST
- Plugin onclick button activate other plugin
- strange shortcode error: does shortcodes requires any dependency?
- How to access OOP plugin function inside themes or other plugin
- Different registration form for different roles
- How can i list random author?
- More gentle way to hook WordPress custom url
- How to get values from network settings panel?
- auto activate plugin when theme is active
- Activation flow of a plugin in a multisite environment
- Checkbox show / hide output result
- How to keep plugin (media-sync) running even the tab is closed?
- How to upload large media file in chunks, without any plugin?
- Error using wordpress functions inside a plugin class
- Allow a particular user to access a particular plugin?
- How to copy the all WordPress media items to another custom plugin folder?
- Cookie value changes back to previous value after changing
- WP Forms not displaying,becomming an fatal error
- Fatal error “Call to undefined function is_plugin_active” each time the plugin is activated
- function post to trash problem
- Custom Plugin: How to Include Install Buttons of other 3rd Party Plugins?
- The function called on the wp head hook becomes null
- adding dynamic/multiple slug values in ‘option_none_value’
- How to capture hidden values with Gravity Forms
- working code, not working – Plugin Dev
- how override a define
- Why my multisite is this slow? (stats inside)
- register_activation_hook doesn’t fire at all
- How To Add Code To WP Without Plugin or Functions
- My ajax request don´t work and return 0
- WordPress Add advertising ads befor and after content with periority [closed]
- plugin not hooking to my custom hook
- Populate select option with JSON file
- How to Call Function From Separate WordPress Install on Same Server?
- Coming soon pages with rest of site in maintenance mode
- Can plugin automatically update if i hide the update notification?
- Why isn’t my plugin seeing other classes?
- how to create table during plugin installation in side a class
- How to add submenu to WordPress plugin in the same Directory of main Plugin?
- Force Network Activated Plugin to Run After Site Level Plugins
- Saving plugin data returns “You do not have sufficient permissions to access this page.”
- How to set the default options on an existing plugin in a WP MU new user install
- How to Overwrite validate_plugin function
- How to add a handler for a button in plugin?
- Check if user is in a group of another site within multisite network [closed]
- Can anyone tell me why I can’t edit a plugin when it is installed without having to re-install?
- Active Plugins for current blog in WP Multisite Network? [duplicate]
- Call current post parameters inside a plugin
- How to list posts that appear in two categories
- Trying to output a “Most visited blogs” list in wordpress multisite
- Pass strings to plugin function [closed]
- Add custom fields in the new and edit the site forms without touching the WP core
- How use Dynamic hyperlink on each wordpress post?
- Send email notification when meet the condition
- Create WordPress category dynamically
- How can I save the selected page in the dropdown after anyone clicks on Save Changes?
- How can I save the selected page in the dropdown after anyone clicks on Save Changes?
- wp_enqueue_script doesn’t load JS in plugin
- Shortcode cannot parse attributes within double quotes. ” is becoming ” breaking my shortcode