You add your _setup
function to wp_head
without priority, so it’s given priority of 20. All of the actions you are trying to remove within that function either have a higher priority (lower number), or same priority but are already in the queue ahead of yours, so when your _setup
function runs, they’ve already sent their output. There’s no reason to wait until wp_head
to remove those actions, you can do it on the init
action.
Also FYI, all your file needs is a plugin header and it’ll be a stand-alone plugin.
Related Posts:
- Serving precompressed content with Brotli on Apache
- How can I avoid code duplication for a blog with lots of source code?
- How to rename wp-includes folder?
- What’s the correct way to include files in WordPress TwentyTen theme with it’s own jquery scripts and css?
- ABSPATH not working! Any idea why?
- Get current user data from external PHP page
- External system integration with wordpress
- Why does get_template_part() break variables?
- How to pass variables with get_template_part?
- Problems Including File
- How to include core files into plugin
- How to check if txt file exists inside template folder?
- What’s the best way to ‘include’ a file in WordPress?
- locate_template function – File not getting included
- Can not include file from plugin into theme
- Include tags from array, ignore the rest in get_the_tags
- PHP files included within functions.php don’t work from admin area
- Wp Enviroment problem with included file
- Having trouble linking to file using relative path
- How can I include an external file in a post or page?
- Including php file in directory above WordPress installation
- add_feed failed to open stream
- Load content From Include File within plugin
- including Zend Gdata library path error
- What about “inc” (include) files and Child Theming? Is it possible?
- Make changes in /includes/http.php update safe
- Need to override file included in parent theme
- Class works in Admin, not found on Front End
- if statement parent page for child pages
- Add page as static html into another page
- Dynamically determine URI to scripts and styles included with a class which could be added from plugin/theme/child theme/mu plugin
- class not declared in scope – even though .h was included
- “Multiple definition”, “first defined here” errors
- Error “Unterminated conditional directive” in cross-referencing headers
- “Fatal error: Cannot redeclare function”
- How to include file in a bash shell script
- Compiler error C4430: missing type specifier – int assumed [duplicate]
- Eclipse CDT: Symbol ‘cout’ could not be resolved
- The proper way to include/require PHP files in WordPress
- How do I replace a function, declared inside a plugin’s class, in functions.php?
- Order by & include array by specific post ids
- load/require specific php files for specific pages/templates/post types
- How can I include JavaScript that use jQuery on admin side
- ob_get_clean returns empty string, ob_get_flush outputs string
- Include files for a plugin not including
- Adding rich text editor to my plugin
- Include Javascript as Plain (No file inclusion)
- Include Class File in WordPress
- nowplaying.include.php Will Not Display Results
- Change title and meta description in included page (not template)
- Include a specific page in your template
- How do I use the Simple HTML DOM Parser in plugin when other plugin already uses it?
- Hardening wordpress: blocking /includes with htaccess
- Looking for a way to include/embed text from a file on a page so that the short codes are processed
- How can I defer these JS files?
- functions.php is being included twice, creating PHP fatal errors
- Custom theme: Alternatives to long list of ‘include’ in functions.php
- How to display / include a specific jpg on a page
- PHP help get_template_directory + PHP include
- Creating plugin using simple_html_dom parser?
- If a page does not exist, include a different page?
- Automatically include all php files in a child theme directory
- Include comments form in plugin page
- Why does abstracting html from plugin code result in loss of access to wordpress functions?
- PHP include is only working in certain places in my custom WP theme
- What is the proper way to include a PHP framework into my theme?
- Can I have an additional functions.php file in WordPress?
- wp_star_rating() – Adding a 5 star rating system to theme
- Include file in plugin file
- confused about wp_list_pages() function – how to display selected top pages with all their subpages
- Unable to point the child theme directory even using get_stylesheet_directory()
- How to get the form code from the edit page of a specific post?
- Trying to include files in plugin isn’t working
- Three step order form, how to go to next step
- Is it ok to chop index.php and include files?
- Custom metabox not working
- How and when to include shortcode source files
- Displaying page content from plugin, inside exising empty WP page
- get_template_part for template in subdirectory not working
- “Cannot modify header information – headers already sent by” while using get_stylesheet_directory_uri()
- How can I include custom Gutenberg Blocks in a theme?
- Before & After Content – After Content directly below Before Content when using require_once
- Including content into an add_shortcode() function
- PHP get_category() function redeclared
- Including admin-options.php file in Child Themes
- How to write wordpress plugins faster to load?
- Push Shortcode parameter to template
- Using require_once for parent-directory not working but is working in sub-directories
- template_redirect and title
- Pages included in another page and duplicate content issues for SEO
- Include a php file that is above WP installation hierarchically?
- How To Display Selected Terms For Custom Taxonomy?
- Want to include ad code after related post
- Custom meta box includes
- Including a PHP file via a function that is part of a plugin?
- strange parse error when including a loop template within another template
- After Migration, Warning: include_once() errors on all pages
- Shortcode return is printing a 1 afterward
- Shortcode to include PHP file, pass various parameters to include?
- Display file contents within Plugin