Closed (won't fix)
Project:
Boost
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
29 Sep 2009 at 10:47 UTC
Updated:
30 Sep 2009 at 02:34 UTC
Mikey, Just thought I should bring this to your notice that Boost (Dev Version dated 27th September 2009) is caching XML sitemap pages even when there are parsing error on some of the sitemap pages.
Comments
Comment #1
mikeytown2 commentedWas Google webmasters tools reporting the parsing error? I think they fixed the issue with xml comments in their engine.
Comment #2
Froggie-2 commentedActually no; the error message was visible on the browser and the page was cached by Boost.
Thanks
Comment #3
mikeytown2 commentedBoost expects the generated xml to be semantically correct. If a module is outputting incorrect markup, it is outside of the the scope of boost to fix it. Having Boost parse the XML looking for errors is also outside the scope of this module. If you wish to validate the document before it is cached, there is hook_boost_preprocess(). If validation fails set
$GLOBALS['_boost_cache_this'] = FALSE.http://php.net/xmlreader.isvalid
I would wait for this patch to go in #585518: Place boost tag inside the closing </html> tag, as it rewrites the API so your hook has access to the extension, so you know what type of document your dealing with.
Just wondering, what part of the xml file failed validation?
Comment #4
mikeytown2 commentedAlso see
http://php.net/domdocument.loadxml
http://php.net/domdocument.validate
Comment #5
Froggie-2 commentedI cannot remember the exact error message but it said something like parsing error and had only a handful of urls in it where as the expected urls were 50000. I wish I had kept a copy of the web page for better understanding and reporting. However, this was just a rare case and I rebuild my sitemap files, this time without any parsing error after manually deleting the faulty cached files.
Now everything appears to be working ok. Sitemap is getting generated and boost is caching them when viewed.
Thanks for your attention though!