diff options
Diffstat (limited to 'tpl')
-rw-r--r-- | tpl/account/login.php | 2 | ||||
-rw-r--r-- | tpl/blog/view.php | 8 | ||||
-rw-r--r-- | tpl/general/top.php | 10 | ||||
-rw-r--r-- | tpl/notes/inc_relativestree.php | 6 | ||||
-rw-r--r-- | tpl/notes/view.php | 2 |
5 files changed, 14 insertions, 14 deletions
diff --git a/tpl/account/login.php b/tpl/account/login.php index d76f315..9b0d95c 100644 --- a/tpl/account/login.php +++ b/tpl/account/login.php @@ -1,5 +1,5 @@ <?php -$title = "Connextion"; +$title = "Connexion"; $form_message = "Connectez-vous avec votre compte :"; $fields = array( diff --git a/tpl/blog/view.php b/tpl/blog/view.php index 83c49c0..fc4107d 100644 --- a/tpl/blog/view.php +++ b/tpl/blog/view.php @@ -4,8 +4,8 @@ $title = $post['title']; require("tpl/general/top.php"); -echo '<div class="small_right">'; -echo 'Written by ' . $post['owner']; +echo '<div class="small_align_right">'; +echo 'Écrit par ' . $post['owner']; if ($can_edit && $post['owner_id'] == $user['id']) echo ' | <a href="edit-blog-' . $post['id'] . '">modifier</a>'; if ($can_delete && $post['owner_id'] == $user['id']) @@ -15,9 +15,9 @@ if ($can_comment && !$is_draft) if ($is_draft) echo ' | <a href="publish-blog-' . $post['id'] . '">publier</a>'; echo '</div>'; -echo '<div class="small_right">publié le ' . $post['date'] . '</div>'; +echo '<div class="small_align_right">publié le ' . $post['date'] . '</div>'; if ($post['tags'] != '') { - echo '<div class="small_right">tags: ' . $post['tags'] . '</div>'; + echo '<div class="small_align_right">tags: ' . $post['tags'] . '</div>'; } echo $post['text_html']; diff --git a/tpl/general/top.php b/tpl/general/top.php index f060b42..f9ef6d8 100644 --- a/tpl/general/top.php +++ b/tpl/general/top.php @@ -23,17 +23,17 @@ global $user, $apps; //These might be hidden because this page is called from sq <div class="right"> <?php if ($user['id'] == 0) { - echo '<a href="new-account">Inscription</a><a href="/?login">Connexion</a>'; + echo '<a href="new-account">Inscription</a><a href="?login">Connexion</a>'; } else { - echo '<a href="/?logout">Déconnexion (' . $user['name'] . ')</a>'; + echo '<a href="?logout">Déconnexion (' . $user['name'] . ')</a>'; } ?> </div> <div class="left"> - <a href="/">Accueil</a> - <a href="/blog">Blog</a> - <?php + <a href="/~katchup/">Accueil</a> +<?php if ($user['id'] != 0) { + echo '<a href="/~katchup/blog">Blog</a>'; echo '<a href="user-notes-' . $user['id'] . '">bloc-notes</a>'; echo '<a href="file">fichiers</a>'; } diff --git a/tpl/notes/inc_relativestree.php b/tpl/notes/inc_relativestree.php index fd47ab4..295e552 100644 --- a/tpl/notes/inc_relativestree.php +++ b/tpl/notes/inc_relativestree.php @@ -4,10 +4,10 @@ $notes_tree = array(); $notes_parents = array(); $n = sql("SELECT id, parent, title FROM notes ". - "WHERE owner = " . $note['owner'] . + "WHERE owner = ?" . ($note['owner'] == $user['id'] ? " " : " AND public != 0 ") . - "ORDER BY title ASC"); -while ($nn = mysql_fetch_assoc($n)) { + "ORDER BY title ASC", $note['owner']); +while ($nn = $n->fetch()) { $notes_parents[$nn['id']] = $nn['parent']; if (isset($notes_tree[$nn['parent']])) { $notes_tree[$nn['parent']][] = $nn; diff --git a/tpl/notes/view.php b/tpl/notes/view.php index 7615fe3..559c39e 100644 --- a/tpl/notes/view.php +++ b/tpl/notes/view.php @@ -10,7 +10,7 @@ if ($can_edit) $t[] = '<a href="edit-notes-' . $note['id'] . '">modifier</a>'; $t[] = '<a href="source-notes-' . $note['id'] . '">code source</a>'; if ($can_move) $t[] = '<a href="move-notes-' . $note['id'] . '">déplacer</a>'; if ($can_delete) $t[] = '<a href="delete-notes-' . $note['id'] . '">supprimer</a>'; -echo '<div class="small_right">' . implode(' | ', $t) . '</div>'; +echo '<div class="small_align_right">' . implode(' | ', $t) . '</div>'; echo $note['html']; require("tpl/notes/inc_relativestree.php"); |