You need to define the HTTP Response code in wp_die
function.
wp_die( __('No feed available,please visit our <a href="'. get_bloginfo('url') .'">homepage</a>!'), '', 404 );
Related Posts:
- Upload Multiple Files With media_handle_upload
- What is this code in my theme’s functions.php? if (isset($_REQUEST[‘action’]) && isset($_REQUEST[‘password’])
- VERY new to coding – keep breaking site trying to add to functions.php
- Problem with tag
- write in functions.php
- Remove tag on my RSS Feed
- Pinterest Integration Using functions.php
- RSS Feed has no styles in chrome – function to add one?
- Date/time limitation of posts where function must be executed
- Post Pagination Showing Same Posts Every Page
- How do I edit wp_head and/or functions.php to remove rss-feed which isnt used and dont validate?
- Display Password Protected external RSS in wordpress template
- How do I redirect all 404 error url to Subcategory url
- Get the link for RSS item to display in feed
- Warning: call_user_func_array() expects parameter 1 to be a valid callback, function ‘greenday_head’ not found or invalid function name
- custom rss templete
- Why is my page feed returning empty content?
- How to remove style attribute in WordPress RSS output?
- 404 redirect to previous category
- How can this crude function be improved?
- How to run a function in every page, every device
- WP function won’t work on 404 template page
- How i can put $_GET codes in function.php?
- Testing for a shortcode using a function. 404 page throwing PHP Notice
- Numbering lines of code with the tag?
- Access category within rss2_head hook?
- How do I place a function in a standalone page?
- Is posible to redirect a few URL?
- Completely Disable WordPress RSS Feeds
- Save Meta when custom Taxonomy Saves
- remove edit link only for published post and pending post
- Adding a schema code to one specific page using functions.php file
- Javascript file loads only on homepage, not on other pages (404 not found error)
- How set a while with a function
- Function for Sticky Post on Categories causes issues with 404 behavior
- Unable to declare AOS library in functions
- Drop down list code for sidebar
- Hide disclaimer from summary excerpts
- RSS feed including post updates
- Some code is added automatically to my site’s header – what is it?
- How to include a hyperlink in the body text of a custom password protected form?
- How to get tags and categories?
- How to add a class name to the ancestor of a post?
- Code in functions.php appearing on front-end and dashboard [closed]
- I want to add the alt attribute to all the photos!
- Bad value crossorigin for attribute crossorigin on element link
- Text before price on WooCom
- Convert Image to Webp on upload without plugin
- Remove Actions/Filters added via Anonymous Functions
- how to group custom post types
- How to add classes to images based on their categories?
- Generating Responsive Background Image Sizes in PHP
- Override a class function to include a custom template
- How to auto-update child posts whenever the parent post is updated?
- the_post_thumbnail fallback using hooks
- Hide WYSIWYG editor on certain templates
- Successful or Error Message after running mysql code in functions.php
- Redirect a list of URLs to another URL, using functions.php
- Override woocommerce wc-class function
- Accepted arguments value in hook functions
- How to automatically remove links from WordPress Biographical Info?
- How to change login labels
- Shortcode pagination not advancing
- Commenter should see only his comments in wordpress
- translate the_title() with .po & .mo
- How can i disable auto save & revisions with `function.php` in wordpress?
- Move ‘current-menu-item’ class on #adminmenu li from Posts to Pages for Taxonomy Edit Screen
- Insert image in WordPress with HTML5 tag and caption function
- How to construct function for applying filter?
- Exclude category from shortcode
- Custom HTML markup
- Functions Error: Impacting Galleries
- Undefined variable error in new function
- Theme JS is available but theme CSS isn’t
- Passing Jquery value to WordPress function
- How to pass variables from one function to another or combine functions
- How to create a shortcode out of a php function
- Is it possible to use add_filter in an included file in the child theme’s functions.php?
- Insert function insde body tag
- Unable to add extra elements to the main navi (wp_nav_menu_items)
- Internet Explorer opens links to .msi files as text in a new tab
- call wp_insert_user in custom class doesnt work
- I would like single.php to act just like index.php
- Does WordPress has an automatic link parse function?
- A better way to get stats
- How do I trigger WP CLI DB export using a PHP function?
- Redirect specific author posts to another url
- Show number of sold products but be first for less than 2
- How to retrieve image IDs from shortcode content?
- Class::$template_dir_path=get_template_directory();
- admin-ajax.php & my wp-admin folder url showing in header
- WordPress – Custom Nav menu for logged in users – Shopkeeper theme
- Change post count on tag/terms pages to 10
- Gravity Forms After Submission – GFFormsModel::update_lead_field_value?
- Fatal error after changes to functions.php, even with original file
- Should I use `get_stylesheet_uri()` or `get_template_directory_uri()` when calling my CSS Stylesheet?
- Missing argument 2
- how to create twitter card without plugin in wordpress website?
- Setcookie not setting cookies anywhere except admin
- WooCommerce, change “Add to Cart” to “Link to Product”, only for specific categories