yacy_search_server/htroot/yacy/ui/ymarks.html
apfelmaennchen 0f7449840e - minor changes on YaCy-UI
git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@4792 6c8d7289-2bf4-0310-a012-ef5d649a1542
2008-05-12 09:42:26 +00:00

66 lines
2.2 KiB
HTML

<script type="text/javascript">
//<![CDATA[
$(document).ready(function() {
$("#side1").accordion("activate", 1);
$("#side3").accordion("activate", 2);
$('#yoptions').resetForm();
$.ajax({
type: "GET",
url: "/xml/bookmarks/xbel/xbel.xml?login=true&tag="+qtag,
dataType: "xml",
success: function(xml) {
$(xml).find('bookmark').each(function(){
var link = $(this).attr('href');
var hash = $(this).attr('id');
var title = $(this).find('title').text();
var date = $(this).attr('added');;
var desc = $(this).find('desc').text();
var pub = $(this).find('metadata[@owner=YaCy][@public]').attr('public');
var tags = $(this).find('metadata[@owner=Mozilla][@ShortcutURL]').attr('ShortcutURL').replace(",",", ","g");
if (pub == "true") {
icon = '<img src="img-2/world2.png" alt="public bookmark" title="public bookmark"/>'
} else {
var icon = '<img src="img-2/lock.png" alt="private bookmark" title="private bookmark"/>'
}
$('<tr></tr')
.html('<td><input type="checkbox" value="true" /></td><td>' +icon+ '</td><td><h3 class="linktitle">' +title+ '</h3><p class="desc">' +desc+ '</p><p class="url"><a href="' +link+ '">' +link+ '</a></p><td>' +tags+ ' </td><td>' +date+ '</td><td><a href="/Bookmarks.html?edit=' +hash+ '"><img src="img-2/pencil.png" alt="edit bookmark" title="edit bookmark" /></a><img src="img-2/cancel.png" alt="delete bookmark" title="delete bookmark"/></td>')
.appendTo('#ymarks tbody');
}); //close each(
$('#ymarks')
.tablesorter({widgets: ['zebra']})
.tablesorterPager({container: $('#pager'), size: 5, positionFixed: false});
}
}); //close $.ajax(
});
//]]>
</script>
<!-- Table -->
<table class="ytable" id="ymarks" summary="YaCy Bookmarks">
<colgroup>
<col width="25"/>
<col width="25"/>
<col width="425"/>
<col width="150"/>
<col width="150"/>
<col width="25"/>
</colgroup>
<thead>
<tr>
<th class="{sorter: false}"></th>
<th></th>
<th>Title</th>
<th>Tags</th>
<th>Date</th>
<th class="{sorter: false}"></th>
</tr>
</thead>
<tbody>
</tbody>
</table>