Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.


Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, biapar, Willr, Ingo, simon_w

XML-parse failure when opening blog on website


6 Posts   1696 Views


23 July 2008 at 6:06am (Last edited: 23 July 2008 6:07am), Community Member, 182 Posts

XML-parsefout: troep na documentelement
Locatie: http://localhost/silverstripe-v2.2.2.1/blog/
Regelnummer 4, kolom 1:<?xml version="1.0" encoding="UTF-8"?>


23 July 2008 at 7:14am Community Member, 182 Posts

This what i get when i try to open the blog page.

Anyone any ideas?


23 July 2008 at 8:42am Community Member, 182 Posts

From source:

<p style="background-color: white; color: black; width: 95%; margin: 0.5em; padding: 0.3em; border: 1px #CCC solid">
<b>Debug (line 118 of BBCodeParser.php):</b>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "">
<html xmlns="" xml:lang="en" >

How come the blog module puts the blog contents (test) above the DOCTYPE???? Offcourse this doesn't work.

Where change this page? I can't find it.


23 July 2008 at 5:49pm Forum Moderator, 5511 Posts

Theres a major bug with the BBCode parser - a Debug::message statement got in there some how. So what its doing since the blog uses BBCode it is using the parser so calling that Debug::message is outputing text before the doctype

You can remove the Debug::message by opening sapphire/parsers/BBCodeParser.php and scrolling down to about line 118 and removing the Debug::message line.


1 November 2008 at 8:26am Community Member, 3 Posts

Hi there! I'm here since a day and I'm pretty happy 'cause this cms rocks! (it really cover all my needs and I hope to be able to help on it some how)
Well, here's the thing... I'm having this debug line too...
Debug (line 118 of BBCodeParser.php)
so I modified parsers/BBCodeParser.php and kick the "Debug::message($this->content);" line of the file...
Well, the error line stills there... I "?flush=1-it"... but nothing works...
I even search for the same line with the finder in the whole instalation but I didnt find another... am I missing something?


3 November 2008 at 11:29am Forum Moderator, 5511 Posts

That should be the only place you need to remove it from. Make sure you didnt have a syntax error or a remove a ; or something where you shouldn't have.