' . "\n";
echo '
\n";
if ($row['bDescription'] == '') {
diff --git a/data/templates/dynamictags.inc.php b/data/templates/dynamictags.inc.php
index b18565b..8cf07c1 100644
--- a/data/templates/dynamictags.inc.php
+++ b/data/templates/dynamictags.inc.php
@@ -36,28 +36,40 @@ $allPopularTagsCount = count($allPopularTags);
// function printing the cloud
-function writeTagsProposition($tagsCloud, $title) {
- echo 'document.write(\'
\');';
- echo 'document.write(\'
'. $title .'<\/h3>\');';
- echo 'document.write(\'
\');';
+function writeTagsProposition($tagsCloud, $title)
+{
+ static $id = 0;
+ ++$id;
+
+ echo <<'
++ ' $title
'
++ ' '
++ '
');
+JS;
$taglist = '';
- foreach(array_keys($tagsCloud) as $key) {
- $row =& $tagsCloud[$key];
+ foreach (array_keys($tagsCloud) as $key) {
+ $row = $tagsCloud[$key];
$entries = T_ngettext('bookmark', 'bookmarks', $row['bCount']);
- $taglist .= '
'. filter($row['tag']) .'<\/span> ';
+ $taglist .= ''
+ . filter($row['tag'])
+ . ' ';
}
-
- echo 'document.write(\''. $taglist .'\');';
- echo 'document.write(\'<\/p>\');';
- echo 'document.write(\'<\/div>\');';
-
+ echo '$(\'#edit-tagcloud-' . $id . ' p\').append('
+ . json_encode($taglist)
+ . ");\n";
}
if ($allPopularTagsCount > 0 || $userPopularTagsCount > 0 ) { ?>
-
-
+
diff --git a/data/templates/editbookmark.tpl.php b/data/templates/editbookmark.tpl.php
index 25524b9..8b71230 100644
--- a/data/templates/editbookmark.tpl.php
+++ b/data/templates/editbookmark.tpl.php
@@ -16,33 +16,41 @@ switch ($row['bStatus']) {
break;
}
-$this->includeTemplate("dojo.inc");
-
function jsEscTitle($title)
{
return addcslashes($title, "'");
}
+function jsEscTitleDouble($title)
+{
+ return addcslashes(addcslashes($title, "'"), "'\\");
+}
+function fixOperaButtonName($name) {
+ //yes, opera has problems with double quotes in button names
+ return str_replace('"', "''", $name);
+}
+
+if (is_array($row['tags'])) {
+ $row['tags'] = implode(', ', $row['tags']);
+}
+
+$ajaxUrl = ROOT . 'ajax/'
+ . (
+ ($GLOBALS['adminsAreAdvisedTagsFromOtherAdmins'] && $currentUser->isAdmin())
+ ? 'getadmintags'
+ : 'getcontacttags'
+ ) . '.php';
?>
-
-
-
-
-
+
+
+
+
+
+
+
+
includeTemplate('dynamictags.inc');
// Bookmarklets and import links
if (empty($_REQUEST['popup']) && (!isset($showdelete) || !$showdelete)) {
+
+$this->includeTemplate('bookmarklet.inc.php');
?>
-
-
-
-
- ()
diff --git a/data/templates/editprofile.tpl.php b/data/templates/editprofile.tpl.php
index b55d250..2a3c3b8 100644
--- a/data/templates/editprofile.tpl.php
+++ b/data/templates/editprofile.tpl.php
@@ -3,9 +3,7 @@ $this->includeTemplate($GLOBALS['top_include']);
?>
\ No newline at end of file
diff --git a/data/templates/sidebar.block.menu.php b/data/templates/sidebar.block.menu.php
index ee82997..94a9fa2 100644
--- a/data/templates/sidebar.block.menu.php
+++ b/data/templates/sidebar.block.menu.php
@@ -65,13 +65,13 @@ if (sizeof($menuTags) > 0 || ($userid != 0 && $userid === $logged_on_userid)) {
getUser($userid); ?>
0): ?>
-