From: x2001corpet Date: Tue, 19 Sep 2006 17:57:13 +0000 (+0000) Subject: fix gestion des liens internes a la page dans les annonces d'accueil X-Git-Tag: xorg/0.9.11~54 X-Git-Url: http://git.polytechnique.org/?a=commitdiff_plain;h=6963e3e3e0111c0a5128aee23b0b65e8ee211f26;p=platal.git fix gestion des liens internes a la page dans les annonces d'accueil git-svn-id: svn+ssh://murphy/home/svn/platal/branches/platal-0.9.11@875 839d8a87-29fc-0310-9880-83ba4fa771e5 --- diff --git a/modules/events.php b/modules/events.php index af01c70..7c96566 100644 --- a/modules/events.php +++ b/modules/events.php @@ -43,7 +43,7 @@ class EventsModule extends PLModule subscribe_nl($uid); } - function handler_ev(&$page, $action = 'list', $eid = null) + function handler_ev(&$page, $action = 'list', $eid = null, $pound = null) { $page->changeTpl('login.tpl'); @@ -114,13 +114,15 @@ class EventsModule extends PLModule INNER JOIN evenements AS e ON e.id = ev.evt_id WHERE peremption < NOW()'); XDB::execute('REPLACE INTO evenements_vus VALUES({?},{?})', - $eid, S::v('uid')); + $eid, S::v('uid')); + pl_redirect('events#'.$pound); } if ($action == 'unread' && $eid) { XDB::execute('DELETE FROM evenements_vus WHERE evt_id = {?} AND user_id = {?}', $eid, S::v('uid')); + pl_redirect('events#newsid'.$eid); } // affichage des evenements diff --git a/templates/login.tpl b/templates/login.tpl index b63745e..a104701 100644 --- a/templates/login.tpl +++ b/templates/login.tpl @@ -87,7 +87,7 @@ Bienvenue {$smarty.session.prenom} {if $smarty.session.perms eq 'admin'} {icon name=page_edit title="Editer cet article"} {/if} - {icon name=cross title="Cacher cet article"} + {icon name=cross title="Cacher cet article"} {assign var="previd" value=$ev.id} @@ -133,7 +133,7 @@ Bienvenue {$smarty.session.prenom} • - + {if $ev.nonlu}{/if} {tidy} {$ev.titre|nl2br}