Jump to content

Topic on Extension talk:WikiArticleFeeds/Archive 2

XML error / XML Verarbeitungsfehler

3
Kappa~mediawikiwiki (talkcontribs)

Since I spent some time in finding the source of the error, I would like to leave a comment here - maybe it helps other users saving debugging time.

After including the extension in our wiki we had an error message: XML-Verarbeitungsfehler: XML- oder Text-Deklaration nicht am Beginn der Entität. When we looked at the HTML-source code of the page generated by MW, we discovered, that the first line of the page was empty. We checked the other extensions in our wiki, and found out that the error was caused by an extension which started with \nl<?php rather than with <?php. We removed the \nl and everything worked fine.

This post was posted by Kappa~mediawikiwiki, but signed as Kappa.

67.177.205.240 (talkcontribs)

Note that this also applies to newlines at the bottom of an extension (past the closing ?> tag). I discovered my error had been in a manually-copied source file for the NoTitle extension. In short, whitespace inside PHP tags is okay, whitespace outside of them is not.

Wikinaut (talkcontribs)

Hi, I maintain this extension, but do not fully understand if you think it is a bug in the extension, or if I should add some lines of code to make the extension more robust to cope with other extensions which break the page HTML.

If you think, there is a problem, even when this is a minor problem, please can you file a bugzilla in our bugtracker, this helps to track it better, and to link to bug fixes and patches in gerrit. On the article page, you find the report a bug link in the info box, or click here.

Thanks in advance (pls. file a bugzilla).

Reply to "XML error / XML Verarbeitungsfehler"