Please upgrade here. These earlier versions are no longer being updated and have security issues.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
XML-Errors: Sitemaps & RSS-Feeds not working after update
intrinsicforce
New
Hey Community,
I installed XML-Sitemaps before Vanilla V.2.1.8 released, and it worked well. I updated to 2.1.8. a few days ago. Now I noticed that the XML files seems to be not generated correctly.
It seems that there's something missing in the XML-File, because this is the error I get:
XML Parse Error: XML or text declaration not at start of entity
This is the source code of a feed.rss:
#
<?xml version="1.0" encoding="utf-8"?> <rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom"> <channel> <title>English - Community</title> <link>http://community.link-removed.com/index.php?p=/categories/general/feed.rss</link> <pubDate>Tue, 27 Jan 2015 11:00:43 +0000</pubDate> <description>English - Community</description> <language>en-CA</language> <atom:link href="http://community.link-removed.com/index.php?p=/categories/general/feed.rss" rel="self" type="application/rss+xml" /> </channel> </rss>
#
Does anyone know if it's correct that the first line is commented out?
Best regards!
0
Comments
Does it validate?
http://validator.w3.org/
Search first
Check out the Documentation! We are always looking for new content and pull requests.
Click on insightful, awesome, and funny reactions to thank community volunteers for their valuable posts.
Hey,
no, it gives me this:
**
Validation Output: 1 Error**
I can not understand this error, isn't the declaration the following line?
<?xml version="1.0" encoding="utf-8"?>It's already at the start of the document....
Mind sharing a link so I can look at it?
This sounds like a plugin is outputting whitespace before the xml declaration.
What kind of plugins are you running?
Search first
Check out the Documentation! We are always looking for new content and pull requests.
Click on insightful, awesome, and funny reactions to thank community volunteers for their valuable posts.
Yes, indeed! You can look at it here: community.deutsche-phytoengineering.de
There are 4 space characters before the xml declaration begins.
I have some plugins, but the error occurs even if I just deactivate them..
If it still doesn't work with all plugins disabled and on the default theme, what is in your
/applications/dashboard/views/rss.master.php
file?Search first
Check out the Documentation! We are always looking for new content and pull requests.
Click on insightful, awesome, and funny reactions to thank community volunteers for their valuable posts.
That's the content:
If it still helps: The Sitemap-Plugin generates XML-Files with the same error as you can see here:
http://community.deutsche-phytoengineering.de/index.php?p=/sitemapindex.xml
https://www.dokuwiki.org/tips:findbadphp.php
Or directly download it:
https://www.dokuwiki.org/_export/code/tips:findbadphp.php?codeblock=0
Copy this into your root folder as a .php file, call it from your browser and report back what you get.
My themes: pure | minusbaseline - My plugins: CSSedit | HTMLedit | InfiniteScroll | BirthdayModule | [all] - PM me about customizations
VanillaSkins.com - Plugins, Themes and Graphics for Vanillaforums OS
okay! I just did it.
Check for whitespace at the start of this file. It could also be a UTF-8 BOM, in which case you have to resave the file without a byte order mark
My themes: pure | minusbaseline - My plugins: CSSedit | HTMLedit | InfiniteScroll | BirthdayModule | [all] - PM me about customizations
VanillaSkins.com - Plugins, Themes and Graphics for Vanillaforums OS
Yeeeeeh! THe bootstrap.after.php contains the 4 whitespaces.
How did you know...
Thank you so much!
hey guys can anybody help me with a similar error, i am new to this so i need baby steps
i am running vanilla 2.1.11 using the cube theme by steam based on bootstrap. i have disabled all plugins and tried to check /applications/dashboard/views/rss.master.php but the file is listed as other file not a php. i haven't tried Bleistivts suggestion as i don't know where my root folder is.
help a newbie learn fellas & thanks in Advance.
Where and how did you upload the Vanilla files? where the index.php file is and the "applications", "cache", "conf", etc. folders are, that's where you have to put the file bleistivt mentioned
thanks for replying @R_J i have installed it on a heartinternet server following vanilla instructions, i will add the file now and update you with my progress.
seems to be very different from the code from the forum above.
Sorry, sometimes I answer without reading the question
What is your problem exactly? Your first screenshot looks good. It shows the XML that forms a discussion feed.
Looking back I didn't even say, so my fault.
My RSS feed button when clicked brings up the XML error. I have used the findbad.php and the image attached above is the results
I also have another niggle with the mobile mode looking a mess but I guess I should start a separate thread for that
Just removing the first line...
<?php echo '<?xml version="1.0" encoding="utf-8"?>'; ?>
...validated my feed. Is this problematic?
If you have whitespace errors you should find them. It is more of a problem than just the feed. Removing the encoding isn't a good idea.
grep is your friend.