• Resolved Alan

    (@alanwhiteman)


    Hi,

    I’m using version 5.0.7 of XML Sitemap & Google News. When trying to view the sitemap, there is a blank page. Upon refresh, the following message appears:

    XML Parsing Error: XML or text declaration not at start of entity
    Location: https://publicspeakinglosangeles.net/sitemap.xml
    Line Number 2, Column 1:<?xml version="1.0" encoding="UTF-8"?>
    ^

    Inspecting the page source, the sitemap is there, but there is a blank line at the start of the file:

    
    [[First line is empty here.]] 
    <?xml version="1.0" encoding="UTF-8"?>
    <?xml-stylesheet type="text/xsl" href="https://publicspeakinglosangeles.net/wp-content/plugins/xml-sitemap-feed/views/styles/sitemap-index.xsl?ver=5.0.7"?>
    <!-- generated-on="2019-02-10T21:09:37+00:00" -->
    <!-- generator="XML & Google News Sitemap Feed plugin for WordPress" -->
    <!-- generator-url="https://status301.net/wordpress-plugins/xml-sitemap-feed/" -->
    <!-- generator-version="5.0.7" -->
    <sitemapindex xmlns="https://www.sitemaps.org/schemas/sitemap/0.9"
    	xmlns:xsi="https://www.w3.org/2001/XMLSchema-instance"
    	xsi:schemaLocation="https://www.sitemaps.org/schemas/sitemap/0.9
    		https://www.sitemaps.org/schemas/sitemap/0.9/siteindex.xsd">
    	<sitemap>
    		<loc>https://publicspeakinglosangeles.net/sitemap-home.xml</loc>
    		<lastmod>2016-01-20T22:41:43+00:00</lastmod>
    	</sitemap>
    	<sitemap>
    		<loc>https://publicspeakinglosangeles.net/sitemap-posttype-post.2016.xml</loc>
    		<lastmod>2016-01-21T04:12:52+00:00</lastmod>
    	</sitemap>
    	<sitemap>
    		<loc>https://publicspeakinglosangeles.net/sitemap-posttype-post.2015.xml</loc>
    		<lastmod>2017-09-01T16:34:37+00:00</lastmod>
    	</sitemap>
    	<sitemap>
    		<loc>https://publicspeakinglosangeles.net/sitemap-posttype-post.2014.xml</loc>
    		<lastmod>2014-12-30T06:35:14+00:00</lastmod>
    	</sitemap>
    	<sitemap>
    		<loc>https://publicspeakinglosangeles.net/sitemap-posttype-page.xml</loc>
    		<lastmod>2018-03-14T23:11:38+00:00</lastmod>
    	</sitemap>
    </sitemapindex>
    

    I’ve already checked wp-config.php and functions.php for extraneous white space. Also, I have the Yoast plugin activated, but with the sitemap feature off.

    Any insight into fixing this will be greatly appreciated.

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Author Rolf Allard van Hagen

    (@ravanh)

    Hi, sorry for the late response. I did not get notified of this thread for some reason… It looks like you solved the issue by switching to another plugin which is perfectly fine of course ??

    White lines can also be caused by a plugin or other theme files (includes) so it might be very difficult to find out where it is coming from unless you would be willing to switch off all other plugins and switch to the default theme temporarily. Then switching back one by one should tell you when the issue re-occurs.

    But it’ll be easier staying with the other sitemap plugin that does not have a problem with that blank line ??

Viewing 1 replies (of 1 total)
  • The topic ‘XML Parssing Error’ is closed to new replies.