2011-06-24, 00:53:59
(This post was last modified: 2011-06-24, 00:55:57 by jacketssale.)
Hello,
Nice plugin! In my case/config (fresh GS install on Apache Windows), one post with accents in its title was enough to make the whole list of posts disappear. The following correction solved the problem:
In inc/cache.php, replaced this:
by this:Just in case it helps anyone. Cheers
Nice plugin! In my case/config (fresh GS install on Apache Windows), one post with accents in its title was enough to make the whole list of posts disappear. The following correction solved the problem:
In inc/cache.php, replaced this:
Code:
function nm_cache_to_xml($posts) {
$xml = new SimpleXMLExtended('<?xml version="1.0" encoding="UTF-8"?><channel></channel>');
foreach ($posts as $post) {
$elem = $xml->addChild('item');
$elem->addChild('slug', $post['slug']);
$elem->addChild('title', $post['title']);
$elem->addChild('date', $post['date']);
$elem->addChild('tags', $post['tags']);
$elem->addChild('private', $post['private']);
}
return @XMLsave($xml, NMPOSTCACHE);
}
Code:
function nm_cache_to_xml($posts) {
$xml = new SimpleXMLExtended('<?xml version="1.0" encoding="UTF-8"?><channel></channel>');
foreach ($posts as $post) {
$item = $xml->addChild('item');
$elem = $item->addChild('slug');
$elem->addCData($post['slug']);
$elem = $item->addChild('title');
$elem->addCData($post['title']);
$elem = $item->addChild('date');
$elem->addCData($post['date']);
$elem = $item->addChild('tags');
$elem->addCData($post['tags']);
$elem = $item->addChild('private');
$elem->addCData($post['private']);
}
return @XMLsave($xml, NMPOSTCACHE);
}