tiki-user_bookmarks.tpl 4.17 KB
Newer Older
1
{title help="User Bookmarks"}{tr}My Bookmarks{/tr}{/title}
2

changi67's avatar
changi67 committed
3
{include file='tiki-mytiki_bar.tpl'}
4

5
{if $parentId>0}[<a class="link" href="tiki-user_bookmarks.php">{tr}top{/tr}</a>] {/if}{tr}Current folder:{/tr} {$path}<br>
sylvieg's avatar
sylvieg committed
6
<h2>{tr}Folders{/tr}</h2>
7
<div class="table-responsive">
8
<table class="table table-striped table-hover">
9 10
	<tr>
		<th>{tr}Name{/tr}</th>
lindonb's avatar
lindonb committed
11
		<th></th>
12
	</tr>
13

14
	{section name=ix loop=$folders}
15
		<tr>
lindonb's avatar
lindonb committed
16 17
			<td class="text"><a class="tips" title=":{tr}Folder in{/tr}" href="tiki-user_bookmarks.php?parentId={$folders[ix].folderId}">
				{icon name='file-archive' }</a>&nbsp;{$folders[ix].name|escape} ({$folders[ix].urls})
18 19
			</td>
			<td class="action">
lindonb's avatar
lindonb committed
20 21
				<a class="tips" title=":{tr}Edit{/tr}" href="tiki-user_bookmarks.php?parentId={$parentId}&amp;editfolder={$folders[ix].folderId}">
					{icon name='edit'}
22
				</a> &nbsp;
lindonb's avatar
lindonb committed
23 24
				<a class="tips" title=":{tr}Remove{/tr}" href="tiki-user_bookmarks.php?parentId={$parentId}&amp;removefolder={$folders[ix].folderId}">
					{icon name='remove'}
25 26 27 28 29 30 31
				</a>
			</td>
		</tr>
	{sectionelse}
		{norecords _colspan=2}
	{/section}
</table>
32
</div>
sylvieg's avatar
sylvieg committed
33 34

<h2>{tr}Bookmarks{/tr}</h2>
35
<div class="table-responsive">
36
	<table class="table table-striped table-hover">
37 38
	<tr>
		<th>{tr}Name{/tr}</th>
39
		<th>{tr}URL{/tr}</th>
lindonb's avatar
lindonb committed
40
		<th></th>
41
	</tr>
42

43
	{section name=ix loop=$urls}
44
		<tr>
45
			<td class="text"><a class="link" target="_blank" href="{$urls[ix].url}">{$urls[ix].name|escape}</a>
46 47 48 49
				{if $tiki_p_cache_bookmarks eq 'y' and $urls[ix].datalen > 0}
					(<a href="tiki-user_cached_bookmark.php?urlid={$urls[ix].urlId}" class="link" target="_blank">{tr}Cache{/tr}</a>)
				{/if}
			</td>
50
			<td class="text">{textformat wrap="60" wrap_cut=true wrap_char="<br>"}{$urls[ix].url}{/textformat}</td>
51
			<td class="action">
lindonb's avatar
lindonb committed
52 53 54
				<a class="tips" title=":{tr}Edit{/tr}" href="tiki-user_bookmarks.php?parentId={$parentId}&amp;editurl={$urls[ix].urlId}">
					{icon name='edit'}
				</a>
55
				{if $tiki_p_cache_bookmarks eq 'y' and $urls[ix].datalen > 0}
lindonb's avatar
lindonb committed
56 57
					<a class="tips" title=":{tr}Refresh cache{/tr}" href="tiki-user_bookmarks.php?parentId={$parentId}&amp;refreshurl={$urls[ix].urlId}">
						{icon name='refresh'}
58 59
					</a>
				{/if}
lindonb's avatar
lindonb committed
60 61 62
				&nbsp; <a class="tips" title=":{tr}Remove{/tr}" href="tiki-user_bookmarks.php?parentId={$parentId}&amp;removeurl={$urls[ix].urlId}">
					{icon name='remove'}
				</a>
63 64 65
			</td>
		</tr>
	{sectionelse}
66
		{norecords _colspan=3}
67
	{/section}
sylvieg's avatar
sylvieg committed
68
</table>
69
</div>
sylvieg's avatar
sylvieg committed
70
<h2>{tr}Admin folders and bookmarks{/tr}</h2>
71
<table class="formcolor">
72 73 74 75 76 77 78
	<tr>
		<td>
			<h3>{if $editfolder}{tr}Edit{/tr}{else}{tr}Add{/tr}{/if} {tr}a folder{/tr}</h3>
			{if $editfolder}
				<a class="link" href="tiki-user_bookmarks.php?parentId={$parentId}&amp;editfolder=0">{tr}New{/tr}</a>
			{/if}
			{* form to add a category *}
79
			<table class="formcolor">
80
				<form action="tiki-user_bookmarks.php" method="post">
81 82
					<input type="hidden" name="editfolder" value="{$editfolder|escape}">
					<input type="hidden" name="parentId" value="{$parentId|escape}">
83
					<tr>
84
						<td>{tr}Name:{/tr}</td>
85
						<td><input type="text" size = "40" name="foldername" value="{$foldername|escape}"></td>
86 87
					</tr>
					<tr>
88 89
						<td>&nbsp;</td>
						<td>
90
							<input type="submit" class="btn btn-primary btn-sm" name="addfolder" value="{tr}Add{/tr}"></td>
91 92 93 94 95 96 97 98 99 100
					</tr>
				</form>
			</table>
		</td>
		<td>
			{* form to add a url *}
			<h3>{if $urlname}{tr}Edit{/tr}{else}{tr}Add{/tr}{/if} {tr}a bookmark{/tr}</h3>
			{if $urlname}
				<a class="link" href="tiki-user_bookmarks.php?parentId={$parentId}&amp;editurl=0">{tr}New{/tr}</a>
			{/if}
101
			<table class="formcolor">
102
				<form action="tiki-user_bookmarks.php" method="post">
103 104
					<input type="hidden" name="editurl" value="{$editurl|escape}">
					<input type="hidden" name="parentId" value="{$parentId|escape}">
105
					<tr>
106
						<td>{tr}Name:{/tr}</td>
107
						<td><input type="text" size = "40" name="urlname" value="{$urlname|escape}"></td>
108 109
					</tr>
					<tr>
110
						<td>{tr}URL:{/tr}</td>
111
						<td><input type="text" size = "40" name="urlurl" value="{$urlurl|escape}"></td>
112 113
					</tr>
					<tr>
114
						<td>&nbsp;</td>
115
						<td><input type="submit" class="btn btn-primary btn-sm" name="addurl" value="{tr}Add{/tr}"></td>
116 117 118 119 120
					</tr>
				</form>
			</table>
		</td>
	</tr>
121
</table>