Hi, as you see in my website
http://ed2k.paradise.free.fr when you click on rss of comments ou wallpapers it gives you a error message on the both files
http://ed2k.paradise.free.fr/rss.php and
http://ed2k.paradise.free.fr/rss-comments.php . So what's the problem please help me quickely. Thanks.
Comments
Make Comments RSS you will find it near random images, and clicke on the rss bouton you will get to a page where i find an error and no comment. I have 4 comments posted an no one is visible.
XML parsing error: <unknown>:3:48: not well-formed (invalid token)
XML parsing error: <unknown>:4:48: not well-formed (invalid token)
This is indeed something we did correct in the nightly (we didn't notice actually). You can alter the rss feeds yourself to solve that by putton `htmspecialchars()` around the gallery title in both feeds (within <title></title>. Or you could use the nightly.
and change it to
`<?php echo htmlspecialchars(getOption('gallery_title')); ?><?php echo htmlspecialchars($albumname); ?>`
<title><?php echo htmlspecialchars(getOption('gallery_title'))." - Derniers Commentaires"; ?></title>
<description><?php echo htmlspecialchars(getOption('gallery_title')); ?></description>
I changed the line of description and the one of title and I have done them like that. Can you help me? Here is the link for the comments rss feed http://ed2k.paradise.free.fr/rss-comments.php
What do you use to read the feed?
`--- O:ZenPhotozenphoto v1.1.6rss-comments.php 2008-03-29 14:19:00.000000000 -0700
+++ O:testalbumzenphotohtdocsrss-comments.php 2008-06-18 15:41:34.000000000 -0700
<?php<br />
if (!defined('ZENFOLDER')) { define('ZENFOLDER', 'zp-core'); }
+define('OFFSET_PATH', 0);
header('Content-Type: application/xml');
require_once(ZENFOLDER . "/template-functions.php");
$themepath = 'themes';
$host = htmlentities($_SERVER["HTTP_HOST"], ENT_QUOTES, 'UTF-8');
if($comment['type'] === "images") {
$imagetag = $imagepath.$comment['filename'].$modrewritesuffix;
} else {
$imagetag = "";
}
$date = $comment['date'];
- $albumtitle = $comment['albumtitle'];
+ $albumtitle = htmlspecialchars($comment['albumtitle']);
if ($comment['title'] == "") $title = $image; else $title = $comment['title'];
$website = $comment['website'];
$shortcomment = truncate_string($comment['comment'], 123);
if(!empty($title)) {
$title = ": ".$title;
}
$count++;
?>
-<?php echo $albumtitle.$title." by ".$author; ?>
+<?php echo htmlspecialchars($albumtitle.$title." by ".$author, ENT_QUOTES); ?>
<?php echo '<![CDATA[http://'.$host.WEBPATH.$albumpath.$album.$imagetag.']]>';?>
-<?php echo $author; ?>
-<?php echo $shortcomment; ?>
-<?php echo $albumtitle; ?>
+<?php echo htmlspecialchars($shortcomment, ENT_QUOTES); ?>
+<?php echo htmlspecialchars($albumtitle, ENT_QUOTES); ?>
<?php echo '<![CDATA[http://'.$host.WEBPATH.$albumpath.$album.$imagetag.']]>';?>
<?php echo fixRSSDate($date); ?>
<?php } ?>
`