From 791f1492478e4497a554c2a3a1c8737c36d71821 Mon Sep 17 00:00:00 2001
From: mensonge
Date: Thu, 24 Apr 2008 08:48:57 +0000
Subject: [PATCH] Interface design: improve tags presentation, menu box, popup
size, redirection after adding a bookmark, RSS link position
git-svn-id: https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/trunk@118 b3834d28-1941-0410-a4f8-b48e95affb8f
---
bookmarks.php | 2 +-
locales/fr_FR/LC_MESSAGES/messages.mo | Bin 19802 -> 19818 bytes
locales/fr_FR/LC_MESSAGES/messages.po | 32 +++++++++++++-------------
locales/messages.po | 26 ++++++++++-----------
services/searchhistoryservice.php | 5 +++-
templates/bookmarks.tpl.php | 14 ++++++++++-
templates/editbookmark.tpl.php | 2 +-
templates/sidebar.block.linked.php | 2 +-
templates/sidebar.block.menu.php | 12 ++++++----
templates/sidebar.block.recent.php | 2 +-
templates/sidebar.block.search.php | 2 +-
templates/sidebar.tpl.php | 5 ----
templates/tag2tagadd.tpl.php | 6 ++---
templates/toolbar.inc.php | 1 +
templates/top.inc.php | 2 ++
15 files changed, 64 insertions(+), 49 deletions(-)
diff --git a/bookmarks.php b/bookmarks.php
index 2adb7bb..a97fb05 100644
--- a/bookmarks.php
+++ b/bookmarks.php
@@ -117,7 +117,7 @@ if ($loggedon && isset($_POST['submitted'])) {
if ($GLOBALS['useredir']) {
$address = $GLOBALS['url_redir'] . $address;
}
- header('Location: '. $address);
+ //header('Location: '. $address); // not useful
}
} else {
$tplVars['error'] = T_('There was an error saving your bookmark. Please try again or contact the administrator.');
diff --git a/locales/fr_FR/LC_MESSAGES/messages.mo b/locales/fr_FR/LC_MESSAGES/messages.mo
index 6012d4c249c9ed9aa7d57ed59faa2b0d2917b7e3..384f10f2535a792ba44cfc6ea03114b918db41a2 100644
GIT binary patch
delta 2485
zcmXZce@vBC9LMo<;c@}F{JL}n1mTJxil8810w!XD{8HyqQI}deW(vx@dfjg6o=hA5
zBWAbdueNI1(ln>u<)&qt8*}~mqZ+s-w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T#KcZGXi%z_c3LuDm(*MITP)jPMpp{qRer&Rx#UAR<=UV~Yz&Psn
zP=_sQops3KQS}nLUV+-07TZ@)0UyF>`~)NM9QrAxmnkTvQy7I;Q5pCX^
z2;7f48y}#q<7rgp=1|}Jb5~W*MBS#Xn20UN6y^;q#z|y1%)dqCUwe{4t1^&_nxF*N
zU>z!uJ*bqui8?%oF%BnDf&Gk{=r`1v2;{(MrIEHNI88ktb=I6jukn|al7AIS?1pAk
zY6ej$K7*ln9&_*#K92WL0oU@3MPq|)H!i1s0QJBeMFnykHO>TT!58rvyyT&v2O)#^
zR|6JeGj2o$a2&Owan!w^#Ha9U)IjlUurij6WYrX++FwNde*hEkHB7)+titL@MNQ;Jt)$Sdm!bA<3o50xr~r21YV5M>@1nNgC}!bV)cdbFCDI{V)YT%FT`Zy}JQ|O1+Q4`$4T3o<%tleS^SKsWxHvHT+W~;T8
zdu=bEKm9&c)>9rNeQ7vIL5E=o73mS=)iswf9p_QkENz>03kp$zJ%`FvFKPjYP~)A!
z*Kq=M77D7ZccdLP-YBNv#cJ~JrZ7tb*)*{a8?yr&F%v&S_0OOt2(GdAG6R*`VpQN&
z7>xB8h)t+K+A#!Qz*X3f%H)TrGx2c^%Uzs^1}6\n"
"Language-Team: fr-FR \n"
"MIME-Version: 1.0\n"
@@ -21,7 +21,7 @@ msgstr ""
#: ../../../about.php:25
#: ../../../templates/toolbar.inc.php:16
-#: ../../../templates/toolbar.inc.php:24
+#: ../../../templates/toolbar.inc.php:25
msgid "About"
msgstr "À propos"
@@ -266,7 +266,7 @@ msgstr "Les informations que vous avez entrées sont incorrectes. Veuillez recom
#: ../../../login.php:48
#: ../../../templates/login.tpl.php:26
-#: ../../../templates/toolbar.inc.php:25
+#: ../../../templates/toolbar.inc.php:26
msgid "Log In"
msgstr "Se connecter"
@@ -318,6 +318,7 @@ msgstr "Mot de passe oublié"
#: ../../../templates/sidebar.block.common.php:9
#: ../../../templates/sidebar.block.popular.php:15
#: ../../../templates/sidebar.block.recent.php:30
+#: ../../../templates/toolbar.inc.php:24
msgid "Popular Tags"
msgstr "Tags populaires"
@@ -385,7 +386,7 @@ msgstr "Enregistrement raté. Veuillez rééssayer."
#: ../../../register.php:66
#: ../../../templates/register.tpl.php:41
-#: ../../../templates/toolbar.inc.php:26
+#: ../../../templates/toolbar.inc.php:27
msgid "Register"
msgstr "S'enregistrer"
@@ -986,18 +987,13 @@ msgstr "Question antispam"
msgid "Linked Tags"
msgstr "Tags structurés"
-#: ../../../templates/sidebar.block.linked.php:44
-#: ../../../templates/sidebar.block.menu.php:31
-msgid "all tags"
-msgstr "Tous les tags"
-
#: ../../../templates/sidebar.block.linked.php:55
-#: ../../../templates/sidebar.block.menu.php:42
+#: ../../../templates/sidebar.block.menu.php:40
msgid "Add new link"
msgstr "Créer un lien"
#: ../../../templates/sidebar.block.linked.php:56
-#: ../../../templates/sidebar.block.menu.php:43
+#: ../../../templates/sidebar.block.menu.php:41
msgid "Delete link"
msgstr "Supprimer un lien"
@@ -1010,9 +1006,13 @@ msgstr "Tags inclus dans le tag '%s'"
msgid "Menu Tags"
msgstr "Menu Tags"
-#: ../../../templates/sidebar.block.menu.php:31
-msgid "See all tags"
-msgstr "Tous les tags"
+#: ../../../templates/sidebar.block.menu.php:60
+msgid "See all your tags"
+msgstr "Voir tous vos tags"
+
+#: ../../../templates/sidebar.block.menu.php:60
+msgid "all your tags"
+msgstr "Tous vos tags"
#: ../../../templates/sidebar.block.recent.php:15
msgid "Recent Tags"
@@ -1062,7 +1062,7 @@ msgstr "Synonymes :"
#: ../../../templates/tag2tagadd.tpl.php:10
#, php-format
msgid "Note: include a tag into '%s' tag (e.g. %s>countries) display the tag into the menu box"
-msgstr "Note inclure une tag dans le tag '%s' (e.g. %s>countries) affiche ce tag dans la boîte de menu"
+msgstr "Note : inclure un tag dans le tag '%s' (e.g. %s>countries) affiche ce tag dans la boîte de menu"
#: ../../../templates/tag2tagadd.tpl.php:13
msgid "Create new link:"
diff --git a/locales/messages.po b/locales/messages.po
index 2dc98f1..d56bb44 100644
--- a/locales/messages.po
+++ b/locales/messages.po
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2008-04-21 17:36+0200\n"
+"POT-Creation-Date: 2008-04-24 09:43+0200\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME \n"
"Language-Team: LANGUAGE \n"
@@ -18,7 +18,7 @@ msgstr ""
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
#: ../../../about.php:25 ../../../templates/toolbar.inc.php:16
-#: ../../../templates/toolbar.inc.php:24
+#: ../../../templates/toolbar.inc.php:25
msgid "About"
msgstr ""
@@ -244,7 +244,7 @@ msgid "The details you have entered are incorrect. Please try again."
msgstr ""
#: ../../../login.php:48 ../../../templates/login.tpl.php:26
-#: ../../../templates/toolbar.inc.php:25
+#: ../../../templates/toolbar.inc.php:26
msgid "Log In"
msgstr ""
@@ -300,6 +300,7 @@ msgstr ""
#: ../../../templates/sidebar.block.common.php:9
#: ../../../templates/sidebar.block.popular.php:15
#: ../../../templates/sidebar.block.recent.php:30
+#: ../../../templates/toolbar.inc.php:24
msgid "Popular Tags"
msgstr ""
@@ -364,7 +365,7 @@ msgid "Registration failed. Please try again."
msgstr ""
#: ../../../register.php:66 ../../../templates/register.tpl.php:41
-#: ../../../templates/toolbar.inc.php:26
+#: ../../../templates/toolbar.inc.php:27
msgid "Register"
msgstr ""
@@ -980,18 +981,13 @@ msgstr ""
msgid "Linked Tags"
msgstr ""
-#: ../../../templates/sidebar.block.linked.php:44
-#: ../../../templates/sidebar.block.menu.php:31
-msgid "all tags"
-msgstr ""
-
#: ../../../templates/sidebar.block.linked.php:55
-#: ../../../templates/sidebar.block.menu.php:42
+#: ../../../templates/sidebar.block.menu.php:40
msgid "Add new link"
msgstr ""
#: ../../../templates/sidebar.block.linked.php:56
-#: ../../../templates/sidebar.block.menu.php:43
+#: ../../../templates/sidebar.block.menu.php:41
msgid "Delete link"
msgstr ""
@@ -1004,8 +1000,12 @@ msgstr ""
msgid "Menu Tags"
msgstr ""
-#: ../../../templates/sidebar.block.menu.php:31
-msgid "See all tags"
+#: ../../../templates/sidebar.block.menu.php:60
+msgid "See all your tags"
+msgstr ""
+
+#: ../../../templates/sidebar.block.menu.php:60
+msgid "all your tags"
msgstr ""
#: ../../../templates/sidebar.block.recent.php:15
diff --git a/services/searchhistoryservice.php b/services/searchhistoryservice.php
index 7389906..bf678cf 100644
--- a/services/searchhistoryservice.php
+++ b/services/searchhistoryservice.php
@@ -43,7 +43,7 @@ class SearchHistoryService {
}
}
- function getAllSearches($range = NULL, $uId = NULL, $nb = NULL, $start = NULL, $distinct = false) {
+ function getAllSearches($range = NULL, $uId = NULL, $nb = NULL, $start = NULL, $distinct = false, $withResults = false) {
$sql = 'SELECT DISTINCT(shTerms), shId, shRange, shNbResults, shDatetime, uId';
$sql.= ' FROM '. $this->getTableName();
$sql.= ' WHERE 1=1';
@@ -55,6 +55,9 @@ class SearchHistoryService {
if($uId != NULL) {
$sql.= ' AND uId = '.$uId;
}
+ if($withResults = true) {
+ $sql.= ' AND shNbResults > 0';
+ }
if($distinct) {
$sql.= ' GROUP BY shTerms';
}
diff --git a/templates/bookmarks.tpl.php b/templates/bookmarks.tpl.php
index dfcf1c7..9277083 100644
--- a/templates/bookmarks.tpl.php
+++ b/templates/bookmarks.tpl.php
@@ -235,7 +235,19 @@ window.onload = playerLoad;
$bnext = ''. T_('Next') .' ';
$blast = ''. T_('Last') ." \n";
}
- echo ''. $bfirst .' / '. $bprev .' / '. $bnext .' / '. $blast .' / '. sprintf(T_('Page %d of %d'), $page, $totalpages) ."
\n";
+
+ // RSS
+ $brss = '';
+ $size = count($rsschannels);
+ for ($i = 0; $i < $size; $i++) {
+ $brss = ' ';
+ }
+
+ echo ''. $bfirst .' / '. $bprev .' / '. $bnext .' / '. $blast .' / '. sprintf(T_('Page %d of %d'), $page, $totalpages) ." ". $brss ."
\n";
+
+
+
+
} else {
echo ''.T_('No bookmarks available').'
';
}
diff --git a/templates/editbookmark.tpl.php b/templates/editbookmark.tpl.php
index 3101431..b4c74ba 100644
--- a/templates/editbookmark.tpl.php
+++ b/templates/editbookmark.tpl.php
@@ -112,7 +112,7 @@ if (window.getSelection) {
}
document.write('
\n";
?>
- →
+ →
getAllSearches('all', NULL, 3, NULL, true);
+$lastSearches = $searchhistoryservice->getAllSearches('all', NULL, 3, NULL, true, true);
if ($lastSearches && count($lastSearches) > 0) {
?>
diff --git a/templates/sidebar.tpl.php b/templates/sidebar.tpl.php
index 7ae1fa1..88915fc 100644
--- a/templates/sidebar.tpl.php
+++ b/templates/sidebar.tpl.php
@@ -6,10 +6,5 @@
for ($i = 0; $i < $size; $i++) {
$this->includeTemplate('sidebar.block.'. $sidebar_blocks[$i]);
}
-
- $size = count($rsschannels);
- for ($i = 0; $i < $size; $i++) {
- echo '
';
- }
?>
diff --git a/templates/tag2tagadd.tpl.php b/templates/tag2tagadd.tpl.php
index 84ee31a..5c82223 100644
--- a/templates/tag2tagadd.tpl.php
+++ b/templates/tag2tagadd.tpl.php
@@ -7,7 +7,6 @@ $this->includeTemplate($GLOBALS['top_include']);
" to include one tag in another. e.g.: europe>france>paris')?>
-countries) display the tag into the menu box'), $GLOBALS['menuTag'], $GLOBALS['menuTag'])?>
@@ -16,8 +15,9 @@ $this->includeTemplate($GLOBALS['top_include']);
-
-
+
+countries) display the tag into the menu box'), $GLOBALS['menuTag'], $GLOBALS['menuTag'])?>
+
diff --git a/templates/toolbar.inc.php b/templates/toolbar.inc.php
index 501222d..ab17bc5 100644
--- a/templates/toolbar.inc.php
+++ b/templates/toolbar.inc.php
@@ -21,6 +21,7 @@ if ($userservice->isLoggedOn()) {
?>
+
diff --git a/templates/top.inc.php b/templates/top.inc.php
index 28fa4fc..58eacb5 100644
--- a/templates/top.inc.php
+++ b/templates/top.inc.php
@@ -32,7 +32,9 @@ if(isset($_GET['popup'])) {
$this->includeTemplate('toolbar.inc');
}
?>
+ if(!isset($_GET['popup'])):?>
+