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.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

Archive /

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

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

XML parsing error requesting draft site when not logged in


Go to End


1282 Views

Avatar
martimiz

Forum Moderator, 1391 Posts

5 November 2008 at 11:14pm

Edited: 05/11/2008 11:16pm

Trying to view the draft site when not logged in (happens when FireFox saves open tabs before closing) I got the following error (version 2.2.3):

XML-parsefout: onjuist gevormd
Locatie: http://www.mydomain.nl/Security/login?BackURL=%2F%3Fstage%3DStage
Regelnummer 44, kolom 105:					<p>You must log in with your CMS password in order to view the draft or archived content.  <a href=\"/home/?stage=Live\">Click here to go back to the published site.</a></p>

I found the solution in the language file en_US.php (5):

$lang['en_US']['ContentController']['DRAFT_SITE_ACCESS_RESTRICTION'] = '... <\"%s\" ...';

This line is surrounded by single quotes that will not 'interprete' the escaping backslashes surrounding %s. Solution: use double quotes or remove the backslashes, both seem to work. This applies to other language files as well.