Use the FixRssFeeds plug-in to fix WordPress Feed display errors.

Source: Internet
Author: User
Tags processing instruction
: This article describes how to use the FixRssFeeds plug-in to fix WordPress Feed display errors. For more information about PHP tutorials, see. Today, a netizen suddenly left a message saying that the blog's Feed has crashed. The symptoms are as follows:

Chrome directly opens the subscription page and displays the following:

This page contains the following errors:error on line 1 at column 1: Document is emptyBelow is a rendering of the page up to the first error.

FeedDemon prompt: this Feed contains an error.

It does not have any impact after being added, and can be used properly.

Fresh fruit reader can also read, but has not obtained the latest article.

I tried it with IE and displayed "invalid content exists at the top level of the document ."

You can view the source code to see the parsed content in the HTML format. This shows that the WordPress Feed output is correct. the problem lies in the format of a file. However, it is difficult to find out which file has a problem. The solutions provided on the Internet are roughly as follows:

Checks whether there are excessive carriage return and line feed characters at the top and bottom.

1. check the wp-config.php file and check whether the code except the PHP subject has a carriage return character;

2, the same as above, detection of wp-rss2.php, wp-atom.php files, if not recently modified, can be skipped;

3. check the functions. php file;

4. Note that the feed is cached. after the modification is complete, send an article to re-create the feed for the WP program to view the effect;

5. if there are still errors, you can temporarily disable all plug-ins, change themes, and eliminate them one by one.

I have modified all the above files, but I still have no clue .. So I installed a plug-in "Fix Rss Feeds" and fixed it after it was enabled. After the fix, deleting the plug-in will not rebound ~

After studying this plug-in, it seems that only the wp-blog-header.php under the WordPress root directory is modified, in fact, you only need to change this file:

<?php/** * Loads the WordPress environment and template. * * @package WordPress */if ( !isset($wp_did_header) ) { $wp_did_header = true;  ob_start(); //2010-09-18 gofunnow.com added, it will Fix rss feed error "Error on line 2: The processing instruction target matching "[xX][mM][lL]" is not allowed." while burn feed from feedburner.com require_once( dirname(__FILE__) . '/wp-load.php' );  ob_end_clean(); //2010-09-18 gofunnow.com added, it will Fix rss feed error "Error on line 2: The processing instruction target matching "[xX][mM][lL]" is not allowed." while burn feed from feedburner.com wp(); require_once( ABSPATH . WPINC . '/template-loader.php' );}?>​

You can.

The above describes how to use the Fix Rss Feeds plug-in to Fix the WordPress Feed display error, including The require content, and hope to help friends who are interested in PHP tutorials.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.