Fixes again
authorx2003bruneau <x2003bruneau@839d8a87-29fc-0310-9880-83ba4fa771e5>
Wed, 8 Nov 2006 10:37:31 +0000 (10:37 +0000)
committerx2003bruneau <x2003bruneau@839d8a87-29fc-0310-9880-83ba4fa771e5>
Wed, 8 Nov 2006 10:37:31 +0000 (10:37 +0000)
git-svn-id: svn+ssh://murphy/home/svn/platal/trunk@1060 839d8a87-29fc-0310-9880-83ba4fa771e5

modules/xnetgrp.php
templates/xnet/groupe/form.announce.tpl

index c5e2dc1..5091835 100644 (file)
@@ -894,8 +894,8 @@ class XnetGrpModule extends PLModule
             $art['event']      = Post::v('event');
 
             $art['contact_html'] = $art['contacts'];
-            if (@$art['event']) {
-                 $art['contact_html'] .= "\n{$globals->baseurl}/{$platal->ns}events/sub/{$art['event']}";
+            if ($art['event']) {
+                $art['contact_html'] .= "\n{$globals->baseurl}/{$platal->ns}events/sub/{$art['event']}";
             }
 
             if (!$art['public'] &&
@@ -923,7 +923,7 @@ class XnetGrpModule extends PLModule
                     require_once('validations.inc.php');
                     require_once('url_catcher.inc.php');
                     $article = new EvtReq("[{$globals->asso('nom')}] " . $art['titre'],
-                                    url_catcher($art['texte'] . (!empty($art['contacts']) ? "\n\nContacts :\n" . $art['contacts'] : "")),
+                                    url_catcher($art['texte'] . (!empty($art['contact_html']) ? "\n\nContacts :\n" . $art['contact_html'] : "")),
                                     $art['promo_min'], $art['promo_max'], $art['peremption'], "", S::v('uid'));
                     $article->submit();
                     $page->trig("L'affichage sur la page d'accueil de Polytechnique.org est en attente de validation");
index d1bb90a..cd95261 100644 (file)
   <tr class="pair">
     <td style="padding-left: 20px">
       {tidy}
+      {if $art.contact_html}
+      {$art.contact_html|nl2br|smarty:nodefaults}
+      {else}
       {$art.contacts|url_catcher|nl2br|smarty:nodefaults}
+      {/if}
       {/tidy}
     </td>
   </tr>