Commit | Line | Data |
---|---|---|
e586807d H |
1 | <!-- |
2 | This program is free software. It comes without any warranty, to | |
3 | the extent permitted by applicable law. You can redistribute it | |
4 | and/or modify it under the terms of the Do What The Fuck You Want | |
5 | To Public License, Version 2, as published by Sam Hocevar. See | |
6 | http://sam.zoy.org/wtfpl/COPYING for more details. | |
7 | --> | |
8 | ||
9 | <head> | |
10 | <script> | |
11 | ||
12 | var current_category; | |
13 | ||
14 | function showBookmark(node_id) {ldelim} | |
15 | var bookmark=document.getElementById(node_id); | |
16 | bookmark.style.visibility="visible"; | |
17 | return true; | |
18 | {rdelim} | |
19 | ||
20 | function setInvisible(id) {ldelim} | |
21 | for (node in categories[id]) {ldelim} | |
22 | document.getElementById(node).style.visibility="hidden"; | |
23 | {rdelim} | |
24 | {rdelim} | |
25 | ||
26 | function showBookmarks(id) {ldelim} | |
27 | setInvisible(current_category); | |
28 | for (node in categories[id]) {ldelim} | |
29 | showBookmark(node); | |
30 | {rdelim} | |
31 | current_category=id; | |
32 | return true; | |
33 | {rdelim} | |
34 | ||
35 | ||
36 | ||
37 | categories=new Object(); | |
38 | categories["0"]=new Object(); | |
39 | {get_bookmark_category} | |
40 | {foreach from=$get_bookmark_category_array item=category}categories["{$category.node_id}"]=new Object();{/foreach} | |
41 | bookmarks=new Array(); | |
42 | {get_bookmark} | |
43 | {foreach from=$get_bookmark_array item=bookmark}categories["{$bookmark.bookmark_category}"]["{$bookmark.node_id}"]=true;{/foreach} | |
44 | </script> | |
45 | <title> | |
46 | bookmarky | |
47 | </title> | |
48 | </head> | |
49 | <body> | |
50 | ||
51 | {section loop=$bookmark_category_array name=category} | |
52 | {circle_coordinates amount=$smarty.section.category.total iteration=$smarty.section.category.index} | |
53 | <div id='category{$smarty.section.category.index}'style='position: absolute; left:{$x_coordinate}px; top:{$y_coordinate}px;'><a onmouseover="category{$smarty.section.category.index}.innerHtml='{$bookmark_category_array[category].node_name}';showBookmarks('{$bookmark_category_array[category].node_id}');" href='/{$bookmark_category_array[category].node_name}/'>::</a></div> | |
54 | {/section} | |
55 | {section loop=$bookmark_array name=bookmarks} | |
56 | {circle_coordinates center_x=$x_coordinate center_y=$y_coordinate amount=$smarty.section.bookmarks.total iteration=$smarty.section.bookmarks.index} | |
57 | <div id='{$bookmark_array[bookmarks].node_id}' style='visibility: hidden; left: {$x_coordinate}px; top: {$y_coordinate}px; position: absolute;'> | |
58 | <a href='/{$bookmark_array[bookmarks].node_name}'>{$bookmark_array[bookmarks].node_name}</a> | |
59 | </div> | |
60 | {/section} | |
61 | ||
62 | </body> |