From c3732aaa843959ea50502a0114c020f55eb95bee Mon Sep 17 00:00:00 2001 From: jjs <jjs@7f39781d-f577-437e-ae19-be835c7a54ca> Date: Tue, 14 Oct 2008 01:06:14 +0000 Subject: [PATCH] [danbooru api] Properly escape source attribute git-svn-id: file:///home/shish/svn/shimmie2/trunk@1074 7f39781d-f577-437e-ae19-be835c7a54ca --- contrib/danbooru_api/main.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/contrib/danbooru_api/main.php b/contrib/danbooru_api/main.php index 342c4d66..678f487a 100644 --- a/contrib/danbooru_api/main.php +++ b/contrib/danbooru_api/main.php @@ -14,6 +14,9 @@ find_posts - sort of works, filename is returned as the original filename and pr find_tags - id, name, and after_id all work but the tags parameter is ignored just like danbooru 1.0 ignores it CHANGELOG +13-OCT-08 8:00PM CST - JJS +Bugfix - Properly escape source attribute + 17-SEP-08 10:00PM CST - JJS Bugfix for changed page name checker in PageRequestEvent @@ -293,7 +296,7 @@ class DanbooruApi implements Extension continue; $taglist = $img->get_tag_list(); $owner = $img->get_owner(); - $xml .= "<post md5=\"$img->hash\" rating=\"Questionable\" date=\"$img->posted\" is_warehoused=\"false\" file_name=\"$img->filename\" tags=\"" . $this->xmlspecialchars($taglist) . "\" source=\"$img->source\" score=\"0\" id=\"$img->id\" author=\"$owner->name\"/>\n"; + $xml .= "<post md5=\"$img->hash\" rating=\"Questionable\" date=\"$img->posted\" is_warehoused=\"false\" file_name=\"$img->filename\" tags=\"" . $this->xmlspecialchars($taglist) . "\" source=\"" . $this->xmlspecialchars($img->source) . "\" score=\"0\" id=\"$img->id\" author=\"$owner->name\"/>\n"; } $xml .= "</posts>"; $page->set_data($xml);