You are viewing the PKP Support Forum | PKP Home Wiki

invalid XML in OAI response

Are you responsible for making OJS work -- installing, upgrading, migrating or troubleshooting? Do you think you've found a bug? Post in this forum.

Moderators: jmacgreg, btbell, michael, bdgregg, barbarah, asmecher

Forum rules
What to do if you have a technical problem with OJS:

1. Search the forum. You can do this from the Advanced Search Page or from our Google Custom Search, which will search the entire PKP site. If you are encountering an error, we especially recommend searching the forum for said error.

2. Check the FAQ to see if your question or error has already been resolved.

3. Post a question, but please, only after trying the above two solutions. If it's a workflow or usability question you should probably post to the OJS Editorial Support and Discussion subforum; if you have a development question, try the OJS Development subforum.

invalid XML in OAI response

Postby elt » Thu Aug 22, 2013 7:49 am

The OAI response to ListRecords and GetRecord with metadataPrefix=nlm for one of our journals is producing an XML validation error because there is a line return preceding the XML declaration in the response.
The response to other OAI verbs with metadataPrefix=nlm is fine, and the response to ListRecords and GetRecord with other metadataPrefixes is also fine.
I can't reproduce this on our other installations.
I'm not sure if this is useful: Turning on database debugging produced "Error code: ERR_CONTENT_DECODING_FAILED" for all OAI verbs, including those that return valid XML.
We are running OJS- with PHP 5.1.6 and mysql 5.0.95
Any suggestions would be really appreciated!
Posts: 9
Joined: Tue Aug 20, 2013 1:34 pm

Re: invalid XML in OAI response

Postby asmecher » Thu Aug 22, 2013 8:41 am

Hi elt,

It's likely that one of the PHP source code files has a blank line inadvertently added to it either at the beginning or the end of the file. Try running a file comparison using "diff" against the stock version of OJS and reviewing the resulting patch file for the change -- these can be hard to find.

Alec Smecher
Public Knowledge Project Team
Posts: 10015
Joined: Wed Aug 10, 2005 12:56 pm

Re: invalid XML in OAI response

Postby elt » Thu Aug 22, 2013 11:36 am

Hi Alec,
Many thanks for the suggestion. I think the problem was related to an old custom plugin. Deleting it seems to have fixed the problem.
Posts: 9
Joined: Tue Aug 20, 2013 1:34 pm

Return to OJS Technical Support

Who is online

Users browsing this forum: Bing [Bot] and 5 guests