now it looks better
authorPierre Habouzit (MadCoder <pierre.habouzit@m4x.org>
Mon, 18 Apr 2005 08:55:57 +0000 (08:55 +0000)
committerFlorent Bruneau <florent.bruneau@polytechnique.org>
Thu, 26 Jun 2008 21:28:37 +0000 (23:28 +0200)
git-archimport-id: opensource@polytechnique.org--2005/platal--mainline--0.9--patch-562

htdocs.net/css/xnet.css
htdocs.net/groupes.php
templates/xnet/groupes.tpl

index 4078327..f9abaec 100644 (file)
@@ -189,19 +189,28 @@ div.cat {
 div.sel { background-color: #5c81aa; color: #d0c198; }
 div.sel a { color: #d0c198; }
 
-td.oval {
+td.oval, td.oval2 {
     color: #d0c198;
-    background: url("../images/oval.png") no-repeat top center;
     height: 50px;
     text-align: center;
     vertical-align: middle !important;
     font-weight: bold;
+}
+td.oval {
+    background: url("../images/oval.png") no-repeat top center;
     width: 130px;
     padding: 4px 12px;
 }
-.oval a { color: #d0c198; }
+td.oval2 {
+    background: url("../images/oval2.png") no-repeat top center;
+    width: 160px;
+    padding: 4px 10px;
+
+}
+
+.oval a, .oval2 a { color: #d0c198; }
 
-#content td.oval {
+#content td.oval, #content td.oval2 {
     font-size: 90%;
     font-family: "Trebuchet MS", sans-serif;
     letter-spacing: -0.5px;
@@ -217,34 +226,3 @@ td.infos {
     color: #505050;
 }
 
-td.pres {
-    background-repeat: no-repeat;
-    background-image: url("images/oval.png");
-    background-position: center center;
-    height: 50px;
-    text-align: center;
-    width: 210px;
-}
-td.pres2 {
-    background-repeat: no-repeat;
-    background-image: url("images/oval2.png");
-    height: 50px;
-    text-align: center;
-    width: 202px;
-}
-
-td.choix1 {
-    height: 30px;
-    background-color: #D0C198;
-    font-size: 100%;
-    color: #5C81AA;
-}
-DIV.choix1 {
-    text-align: center;
-}
-td.choix1actif {
-    height: 30px;
-    vertical-align: middle;
-    text-decoration: none;
-}
-
index 5d0565f..7547471 100644 (file)
@@ -11,6 +11,7 @@
 
     $res = $globals->xdb->iterator("SELECT id,nom FROM groupex.dom WHERE FIND_IN_SET({?}, cat) ORDER BY nom", $cat);
     $page->assign('doms', $res);
+    $page->assign('hasdom', $res->total()!=0);
     
     if (!$res->total()) {
         $res = $globals->xdb->iterator("SELECT diminutif, nom FROM groupex.asso WHERE FIND_IN_SET({?}, cat) ORDER BY nom", $cat);
index 84732de..0a08b79 100644 (file)
     <td>
       <table cellspacing="0" cellpadding="4">
         <tr>
-          <td colspan="2">
+          <td{if $hasdom} colspan="2"{/if}>
             {include file="xnet/include/descr.tpl" cat=$smarty.get.cat}
           </td>
         </tr>
-
         <tr>
-          <!-- Enumération de tous les domaines existants dans la catégorie concernées -->
+          {if $hasdom}
           <td style="vertical-align: top">
             {iterate from=$doms item=g}
             <div class="cat {if $g.id eq $smarty.get.dom}sel{/if}">
             </div>
             {/iterate}
           </td>
-          <td>
+          {/if}
+          <td style="text-align:right;">
             {if $gps}
             {iterate from=$gps item=g}
             <table style="float: left;" cellspacing="2" cellpadding="0">
-              <tr>
-                <td class="oval"><a href="...">{$g.nom}</a></td>
-              </tr>
+              <tr><td class="oval{if $hasdom}2{/if}"><a href="...">{$g.nom}</a></td></tr>
             </table>
             {/iterate}
             {else}