small fix to correct encoding of xml output

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@5473 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
apfelmaennchen 16 years ago
parent efe801173c
commit 9b26dfec80

@ -163,11 +163,17 @@ public class get_bookmarks {
prop.put("display_bookmarks_"+count+"_hash", bookmark.getUrlHash());
prop.put("display_bookmarks_"+count+"_comma", ",");
// offer both HTML encoded
prop.putHTML("display_bookmarks_"+count+"_title-enc", bookmark.getTitle());
prop.putHTML("display_bookmarks_"+count+"_desc-enc", bookmark.getDescription());
prop.putHTML("display_bookmarks_"+count+"_tags-enc", bookmark.getTagsString().replaceAll(",", ", "));
prop.putHTML("display_bookmarks_"+count+"_folders-enc", (bookmark.getFoldersString()));
// offer HTML encoded
prop.putHTML("display_bookmarks_"+count+"_title-html", bookmark.getTitle());
prop.putHTML("display_bookmarks_"+count+"_desc-html", bookmark.getDescription());
prop.putHTML("display_bookmarks_"+count+"_tags-html", bookmark.getTagsString().replaceAll(",", ", "));
prop.putHTML("display_bookmarks_"+count+"_folders-html", (bookmark.getFoldersString()));
// XML encoded
prop.putXML("display_bookmarks_"+count+"_title-xml", bookmark.getTitle());
prop.putXML("display_bookmarks_"+count+"_desc-xml", bookmark.getDescription());
prop.putXML("display_bookmarks_"+count+"_tags-xml", bookmark.getTagsString());
prop.putXML("display_bookmarks_"+count+"_folders-xml", (bookmark.getFoldersString()));
// and plain text (potentially unsecure)
prop.put("display_bookmarks_"+count+"_title", bookmark.getTitle());

@ -17,9 +17,9 @@ rows: [
{id:"#[id]#",cell:[
"#[hash]#",
#(public)#"<img src='img-2/world2.png' alt='public' title='public bookmark'/>"::"<img src='img-2/lock.png' alt='private' title='private bookmark'/>"#(/public)#,
"<h3 class='linktitle'>#[title-enc]#</h3><p class='desc'>#[desc-enc]#</p><p class='url'><a href='#[link]#'>#[link]#</a>",
"<p class='tags'>#[tags-enc]#</p>",
"<p class='folders'>#[folders-enc]#</p>",
"<h3 class='linktitle'>#[title-html]#</h3><p class='desc'>#[desc-html]#</p><p class='url'><a href='#[link]#'>#[link]#</a>",
"<p class='tags'>#[tags-html]#</p>",
"<p class='folders'>#[folders-html]#</p>",
"<p class='date'>#[rfc822date]#</p>"]}#[comma]#
#{/bookmarks}#
]

@ -3,7 +3,7 @@
<!-- DOCTYPE YaCy Bookmarks http://www.yacy.net -->
<posts>
#{bookmarks}#
<post href="#[link]#" description="#[title]#" extended="#[desc]#" hash="#[hash]#" tag="#[tags]#" time="#[date]#" #(public)#private="false"::private="true"#(/public)#/>
<post href="#[link]#" description="#[title-xml]#" extended="#[desc-xml]#" hash="#[hash]#" tag="#[tags-xml]#" time="#[date]#" #(public)#private="false"::private="true"#(/public)#/>
#{/bookmarks}#
</posts>
::
@ -15,9 +15,9 @@
<cell><![CDATA[#[hash]#]]></cell>
#(public)#<cell><![CDATA[<img src='img-2/world2.png' alt='public' title='public bookmark'/>]]></cell>::
<cell><![CDATA[<img src='img-2/lock.png' alt='private' title='private bookmark'/>]]></cell>#(/public)#
<cell><![CDATA[<h3 class='linktitle'>#[title-enc]#</h3><p class='desc'>#[desc-enc]#</p><p class='url'><a href='#[link]#'>#[link]#</a>]]></cell>
<cell><![CDATA[<p class='tags'>#[tags-enc]#</p>]]></cell>
<cell><![CDATA[<p class='folders'>#[folders-enc]#</p>]]></cell>
<cell><![CDATA[<h3 class='linktitle'>#[title-html]#</h3><p class='desc'>#[desc-html]#</p><p class='url'><a href='#[link]#'>#[link]#</a>]]></cell>
<cell><![CDATA[<p class='tags'>#[tags-html]#</p>]]></cell>
<cell><![CDATA[<p class='folders'>#[folders-html]#</p>]]></cell>
<cell><![CDATA[<p class='date'>#[rfc822date]#</p>]]></cell>
</row>#{/bookmarks}#
</rows>
@ -41,12 +41,12 @@
<description><![CDATA[#[user]#'s Bookmark-Feed]]></description>
</channel>
#{bookmarks}#<item>
<title><![CDATA[#[title]#]]></title>
<title><![CDATA[#[title-xml]#]]></title>
<link>#[link]#</link>
<pubDate>#[rfc822date]#</pubDate>
<guid>#[hash]#</guid>
<description><![CDATA[<p>#[desc]#</p>]]></description>
<category><![CDATA[#[tags]#]]></category>
<description><![CDATA[<p>#[desc-xml]#</p>]]></description>
<category><![CDATA[#[tags-xml]#]]></category>
</item>#{/bookmarks}#
</rss>
#(/display)#

Loading…
Cancel
Save