Espace entre les catégorie phpBB3

Forum consacré à phpBB lui même. Comment tirer le meilleur de ce puissant forum.
Veuillez noter que ce forum n'est pas un forum de support officiel, il s'agit ici plus de partager que de demander.

Modérateur: Modérateurs

Espace entre les catégorie phpBB3

Messagede landry » Mar Mar 25, 2008 8:00 pm

Bonjour,

Comme sur l'index de php-seo ou comme sur l'index actuel de mon forum phpBB2 je souhaiterai créer un espace entre les catégories de phpBB3, thème subsilver2.

Pour phpBB2 j'avais suivi ce MOD :



Code: Tout sélectionner
http://www.phpbb.com/community/viewtopic.php?f=15&t=108765&st=0&sk=t&sd=a&start=30

http://www.phpbb.com/phpBB/viewtopic.php?t=108765

##############################################################
## MOD Title: Split Categories On Index
## MOD Author: DanielT < scoi.mods@danielt.com > (Daniel Taylor) http://www.danielt.com
## MOD Description: Splits up the category areas on your index page
## MOD Version: 1.0.2
##
## Installation Level: easy
## Installation Time: ~1 Minutes
## Files To Edit: index_body.tpl
## Included Files: n/a
##############################################################
## For Security Purposes, Please Check: http://www.phpbb.com/mods/ for the
## latest version of this MOD. Downloading this MOD from other sites could cause malicious code
## to enter into your phpBB Forum. As such, phpBB will not offer support for MOD's not offered
## in our MOD-Database, located at: http://www.phpbb.com/mods/
##############################################################
## Author Notes: n/a
##############################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
##############################################################
#
#-----[ OPEN ]------------------------------------------
#
templates/subSilver/index_body.tpl
#
#-----[ FIND ]------------------------------------------
#
<table width="100%" cellpadding="2" cellspacing="1" border="0" class="forumline">
  <tr>
   <th colspan="2" class="thCornerL" height="25" nowrap="nowrap">&nbsp;{L_FORUM}&nbsp;</th>
   <th width="50" class="thTop" nowrap="nowrap">&nbsp;{L_TOPICS}&nbsp;</th>
   <th width="50" class="thTop" nowrap="nowrap">&nbsp;{L_POSTS}&nbsp;</th>
   <th class="thCornerR" nowrap="nowrap">&nbsp;{L_LASTPOST}&nbsp;</th>
  </tr>
  <!-- BEGIN catrow -->
  <tr>
   <td class="catLeft" colspan="2" height="28"><span class="cattitle"><a href="{catrow.U_VIEWCAT}" class="cattitle">{catrow.CAT_DESC}</a></span></td>
   <td class="rowpic" colspan="3" align="right">&nbsp;</td>
  </tr>
  <!-- BEGIN forumrow -->
  <tr>
   <td class="row1" align="center" valign="middle" height="50"><img src="{catrow.forumrow.FORUM_FOLDER_IMG}" width="46" height="25" alt="{catrow.forumrow.L_FORUM_FOLDER_ALT}" title="{catrow.forumrow.L_FORUM_FOLDER_ALT}" /></td>
   <td class="row1" width="100%" height="50"><span class="forumlink"> <a href="{catrow.forumrow.U_VIEWFORUM}" class="forumlink">{catrow.forumrow.FORUM_NAME}</a><br />
     </span> <span class="genmed">{catrow.forumrow.FORUM_DESC}<br />
     </span><span class="gensmall">{catrow.forumrow.L_MODERATOR} {catrow.forumrow.MODERATORS}</span></td>
   <td class="row2" align="center" valign="middle" height="50"><span class="gensmall">{catrow.forumrow.TOPICS}</span></td>
   <td class="row2" align="center" valign="middle" height="50"><span class="gensmall">{catrow.forumrow.POSTS}</span></td>
   <td class="row2" align="center" valign="middle" height="50" nowrap="nowrap"> <span class="gensmall">{catrow.forumrow.LAST_POST}</span></td>
  </tr>
  <!-- END forumrow -->
  <!-- END catrow -->
</table>
#
#-----[ REPLACE WITH ]------------------------------------
#
<!-- BEGIN catrow -->
<table width="100%" cellpadding="2" cellspacing="1" border="0" class="forumline">
  <tr>
   <th colspan="2" class="thCornerL" height="25" nowrap="nowrap">&nbsp;{L_FORUM}&nbsp;</th>
   <th width="50" class="thTop" nowrap="nowrap">&nbsp;{L_TOPICS}&nbsp;</th>
   <th width="50" class="thTop" nowrap="nowrap">&nbsp;{L_POSTS}&nbsp;</th>
   <th class="thCornerR" nowrap="nowrap">&nbsp;{L_LASTPOST}&nbsp;</th>
  </tr>
  <tr>
   <td class="catLeft" colspan="2" height="28"><span class="cattitle"><a href="{catrow.U_VIEWCAT}" class="cattitle">{catrow.CAT_DESC}</a></span></td>
   <td class="rowpic" colspan="3" align="right">&nbsp;</td>
  </tr>
  <!-- BEGIN forumrow -->
  <tr>
   <td class="row1" align="center" valign="middle" height="50"><img src="{catrow.forumrow.FORUM_FOLDER_IMG}" width="46" height="25" alt="{catrow.forumrow.L_FORUM_FOLDER_ALT}" title="{catrow.forumrow.L_FORUM_FOLDER_ALT}" /></td>
   <td class="row1" width="100%" height="50"><span class="forumlink"> <a href="{catrow.forumrow.U_VIEWFORUM}" class="forumlink">{catrow.forumrow.FORUM_NAME}</a><br />
     </span> <span class="genmed">{catrow.forumrow.FORUM_DESC}<br />
     </span><span class="gensmall">{catrow.forumrow.L_MODERATOR} {catrow.forumrow.MODERATORS}</span></td>
   <td class="row2" align="center" valign="middle" height="50"><span class="gensmall">{catrow.forumrow.TOPICS}</span></td>
   <td class="row2" align="center" valign="middle" height="50"><span class="gensmall">{catrow.forumrow.POSTS}</span></td>
   <td class="row2" align="center" valign="middle" height="50" nowrap="nowrap"> <span class="gensmall">{catrow.forumrow.LAST_POST}</span></td>
  </tr>
  <!-- END forumrow -->
  </table>
  <br />
  <!-- END catrow -->
#
#-----[ SAVE/CLOSE ALL FILES ]---------------------------
# EoM




Modifier aussi index-php car le MOD Today-Yesterday deforme l'index en cas de pseudo trop longs :

#-----[ OPEN ]------------------------------------------
#
templates/subSilver/index.php
#
#-----[ FIND ]------------------------------------------
#
                        $last_post .= '<span class="date-general">' . $last_post_time . '</span><br />' . $lang['yesterday-today_by'] . ' '; 
#
#-----[ ADD AFTER ]------------------------------------------
#
         if (strlen($forum_data[$j]['username']) > 10) {
                 $forum_data[$j]['username'] = substr($forum_data[$j]['username'], 0, 10).' ...';
             }

#
#-----[ SAVE/CLOSE ALL FILES ]---------------------------
# DCZ


Pour phpBB3 je séche grâve. Je suppose que l'intervention doit se faire au niveau de forumlist_body mais où et comment ?

Voici forumlist_body :

Code: Tout sélectionner
<table class="tablebg" cellspacing="1" width="100%">
<tr>
   <td class="cattop" colspan="5" align="{S_CONTENT_FLOW_END}"><!-- IF not S_IS_BOT and U_MARK_FORUMS --><a class="nav" href="{U_MARK_FORUMS}">{L_MARK_FORUMS_READ}</a><!-- ENDIF -->&nbsp;</td>
</tr>
<tr>
   <th colspan="2">&nbsp;{L_FORUM}&nbsp;</th>
   <th width="50">&nbsp;{L_TOPICS}&nbsp;</th>
   <th width="50">&nbsp;{L_POSTS}&nbsp;</th>
   <th>&nbsp;{L_LAST_POST}&nbsp;</th>
</tr>
<!-- BEGIN forumrow -->
   <!-- IF forumrow.S_IS_CAT -->
      <tr>
         <td class="cat" colspan="2"><h4><a href="{forumrow.U_VIEWFORUM}">{forumrow.FORUM_NAME}</a></h4></td>
         <td class="catdiv" colspan="3">&nbsp;</td>
      </tr>
   <!-- ELSEIF forumrow.S_IS_LINK -->
      <tr>
         <td class="row1" width="50" align="center">{forumrow.FORUM_FOLDER_IMG}</td>
         <td class="row1">
            <!-- IF forumrow.FORUM_IMAGE -->
               <div style="float: {S_CONTENT_FLOW_BEGIN}; margin-{S_CONTENT_FLOW_END}: 5px;">{forumrow.FORUM_IMAGE}</div><div style="float: {S_CONTENT_FLOW_BEGIN};">
            <!-- ENDIF -->
            <a class="forumlink" href="{forumrow.U_VIEWFORUM}">{forumrow.FORUM_NAME}</a>
            <p class="forumdesc">{forumrow.FORUM_DESC}</p>
            <!-- IF forumrow.FORUM_IMAGE --></div><!-- ENDIF -->
         </td>
         <!-- IF forumrow.CLICKS -->
            <td class="row2" colspan="3" align="center"><span class="genmed">{L_REDIRECTS}: {forumrow.CLICKS}</span></td>
         <!-- ELSE -->
            <td class="row2" colspan="3" align="center">&nbsp;</td>
         <!-- ENDIF -->
      </tr>
   <!-- ELSE -->
      <!-- IF forumrow.S_NO_CAT -->
         <tr>
            <td class="cat" colspan="2"><h4>{L_FORUM}</h4></td>
            <td class="catdiv" colspan="3">&nbsp;</td>
         </tr>
      <!-- ENDIF -->
      <tr>
         <td class="row1" width="50" align="center">{forumrow.FORUM_FOLDER_IMG}</td>
         <td class="row1" width="100%">
            <!-- IF forumrow.FORUM_IMAGE -->
               <div style="float: {S_CONTENT_FLOW_BEGIN}; margin-{S_CONTENT_FLOW_END}: 5px;">{forumrow.FORUM_IMAGE}</div><div style="float: {S_CONTENT_FLOW_BEGIN};">
            <!-- ENDIF -->
            <a class="forumlink" href="{forumrow.U_VIEWFORUM}">{forumrow.FORUM_NAME}</a>
            <p class="forumdesc">{forumrow.FORUM_DESC}</p>
            <!-- IF forumrow.MODERATORS -->
               <p class="forumdesc"><strong>{forumrow.L_MODERATOR_STR}:</strong> {forumrow.MODERATORS}</p>
            <!-- ENDIF -->
            <!-- IF forumrow.SUBFORUMS -->
               <p class="forumdesc"><strong>{forumrow.L_SUBFORUM_STR}</strong> {forumrow.SUBFORUMS}</p>
            <!-- ENDIF -->
            <!-- IF forumrow.FORUM_IMAGE --></div><!-- ENDIF -->
         </td>
         <td class="row2" align="center"><p class="topicdetails">{forumrow.TOPICS}</p></td>
         <td class="row2" align="center"><p class="topicdetails">{forumrow.POSTS}</p></td>
         <td class="row2" align="center" nowrap="nowrap">
            <!-- IF forumrow.LAST_POST_TIME -->
               <p class="topicdetails">{forumrow.LAST_POST_TIME}</p>
               <p class="topicdetails">{forumrow.LAST_POSTER_FULL}
                  <a href="{forumrow.U_LAST_POST}">{LAST_POST_IMG}</a>
               </p>
            <!-- ELSE -->
               <p class="topicdetails">{L_NO_POSTS}</p>
            <!-- ENDIF -->
         </td>
      </tr>
   <!-- ENDIF -->
<!-- BEGINELSE -->
   <tr>
      <td class="row1" colspan="5" align="center"><p class="gensmall">{L_NO_FORUMS}</p></td>
   </tr>
<!-- END forumrow -->
</table>


Merci :wink:
landry
PR2
PR2
 
Messages: 278
Inscription: Mer Sep 06, 2006 8:44 am
Localisation: Carcassonne (France)

Publicité

Messagede landry » Mer Mar 26, 2008 6:21 pm

Ce que je ne saisis pas c'est que cet affichage soit présent par défaut sur le thème Prosilver et que je ne puisse pas l'adapter à subsilver [img]http://www.micro-astuce.com/Forum/images/smiles/compren2[1].gif[/img]
landry
PR2
PR2
 
Messages: 278
Inscription: Mer Sep 06, 2006 8:44 am
Localisation: Carcassonne (France)

Messagede MathieuM. » Mer Mar 26, 2008 7:24 pm

Prosilver n'a absolument pas la même structure que subSilver (qui n'est fait que de cadres tout pas beau, enfin, à mon goût), donc pas étonnant.

Si personne ne te solutionne ça avant, j'essaie de jeter un oeil ce week-end sur subSilver2.


Mathieu.
Avatar de l’utilisateur
MathieuM.
phpBB SEO Team
phpBB SEO Team
 
Messages: 1465
Inscription: Dim Fév 10, 2008 9:33 pm
Localisation: Rhône-Alpes

Messagede landry » Mer Mar 26, 2008 8:57 pm

Bonsoir,

Moi c'est le Prosilver qui ne me plaît pas. Il fait un peu "M'as tu vu ?". Puis je n'apprècie pas l'interface même lors navigation. Mais bon c'est un avis perso.
En revanche j'ai peur que le théme subsilver2 soit laissè un peu de côté en ce qui concerne les maj manuelles et les MOD. On verra bien. Dans ce cas j'aviserai.
Me faudrait un phpBB3 façon phpBB2 pour être satisfait. :lol:

Si personne ne te solutionne ça avant, j'essaie de jeter un oeil ce week-end sur subSilver2.


Ce serait très sympa de ta part, je viens encore d'y passer une petit heure dessus, y'a pas moyen. Quand ça veut pas, ça veut pas.

Merci à toi.

++
landry
PR2
PR2
 
Messages: 278
Inscription: Mer Sep 06, 2006 8:44 am
Localisation: Carcassonne (France)

Messagede landry » Sam Mar 29, 2008 7:54 am

Salut MathieuM.,

Ben je suis toujours sans réponse, alors si tu as deux minutes ce WE pour regarder mon problème je serais prenneur.

Merci. :D
landry
PR2
PR2
 
Messages: 278
Inscription: Mer Sep 06, 2006 8:44 am
Localisation: Carcassonne (France)

Messagede landry » Sam Mar 29, 2008 6:13 pm

Finalement c'est réglé.

BalHack sur phpBB-fr.com a trouvé la solution.
Je la copie ici dans le cas ou ça interesserait quelqu'un.


Ouvrir forumlist_body.html de Subsilver2 et remplacer le contenu par :

<!-- BEGIN forumrow -->
<!-- IF forumrow.S_IS_CAT -->
<br />
<table class="tablebg" cellspacing="1" width="100%">
<tr>
<th colspan="2">&nbsp;{L_FORUM}&nbsp;</th>
<th width="50">&nbsp;{L_TOPICS}&nbsp;</th>
<th width="50">&nbsp;{L_POSTS}&nbsp;</th>
<th>&nbsp;{L_LAST_POST}&nbsp;</th>
</tr>
<tr>
<td class="cat" colspan="2"><h4><a href="{forumrow.U_VIEWFORUM}">{forumrow.FORUM_NAME}</a></h4></td>
<td class="catdiv" colspan="3">&nbsp;</td>
</tr>
<!-- ELSEIF forumrow.S_IS_LINK -->
<tr>
<td class="row1" width="50" align="center">{forumrow.FORUM_FOLDER_IMG}</td>
<td class="row1">
<!-- IF forumrow.FORUM_IMAGE -->
<div style="float: {S_CONTENT_FLOW_BEGIN}; margin-{S_CONTENT_FLOW_END}: 5px;">{forumrow.FORUM_IMAGE}</div><div style="float: {S_CONTENT_FLOW_BEGIN};">
<!-- ENDIF -->
<a class="forumlink" href="{forumrow.U_VIEWFORUM}">{forumrow.FORUM_NAME}</a>
<p class="forumdesc">{forumrow.FORUM_DESC}</p>
<!-- IF forumrow.FORUM_IMAGE --></div><!-- ENDIF -->
</td>
<!-- IF forumrow.CLICKS -->
<td class="row2" colspan="3" align="center"><span class="genmed">{L_REDIRECTS}: {forumrow.CLICKS}</span></td>
<!-- ELSE -->
<td class="row2" colspan="3" align="center">&nbsp;</td>
<!-- ENDIF -->
</tr>
<!-- ELSE -->
<!-- IF forumrow.S_NO_CAT -->
<tr>
<td class="cat" colspan="2"><h4>{L_FORUM}</h4></td>
<td class="catdiv" colspan="3">&nbsp;</td>
</tr>
<!-- ENDIF -->
<tr>
<td class="row1" width="50" align="center">{forumrow.FORUM_FOLDER_IMG}</td>
<td class="row1" width="100%">
<!-- IF forumrow.FORUM_IMAGE -->
<div style="float: {S_CONTENT_FLOW_BEGIN}; margin-{S_CONTENT_FLOW_END}: 5px;">{forumrow.FORUM_IMAGE}</div><div style="float: {S_CONTENT_FLOW_BEGIN};">
<!-- ENDIF -->
<a class="forumlink" href="{forumrow.U_VIEWFORUM}">{forumrow.FORUM_NAME}</a>
<p class="forumdesc">{forumrow.FORUM_DESC}</p>
<!-- IF forumrow.MODERATORS -->
<p class="forumdesc"><strong>{forumrow.L_MODERATOR_STR}:</strong> {forumrow.MODERATORS}</p>
<!-- ENDIF -->
<!-- IF forumrow.SUBFORUMS -->
<p class="forumdesc"><strong>{forumrow.L_SUBFORUM_STR}</strong> {forumrow.SUBFORUMS}</p>
<!-- ENDIF -->
<!-- IF forumrow.FORUM_IMAGE --></div><!-- ENDIF -->
</td>
<td class="row2" align="center"><p class="topicdetails">{forumrow.TOPICS}</p></td>
<td class="row2" align="center"><p class="topicdetails">{forumrow.POSTS}</p></td>
<td class="row2" align="center" nowrap="nowrap">
<!-- IF forumrow.LAST_POST_TIME -->
<p class="topicdetails">{forumrow.LAST_POST_TIME}</p>
<p class="topicdetails">{forumrow.LAST_POSTER_FULL}
<a href="{forumrow.U_LAST_POST}">{LAST_POST_IMG}</a>
</p>
<!-- ELSE -->
<p class="topicdetails">{L_NO_POSTS}</p>
<!-- ENDIF -->
</td>
</tr>
<!-- ENDIF -->
<!-- BEGINELSE -->
<tr>
<td class="row1" colspan="5" align="center"><p class="gensmall">{L_NO_FORUMS}</p></td>
</tr>
</table>
<!-- END forumrow -->
<br />
<table class="tablebg" cellspacing="1" width="100%">
<tr>
<td class="cat" colspan="5" align="{S_CONTENT_FLOW_END}"><!-- IF not S_IS_BOT and U_MARK_FORUMS --><a class="nav" href="{U_MARK_FORUMS}">{L_MARK_FORUMS_READ}</a><!-- ENDIF -->&nbsp;</td>
</tr>
</table>


:D
landry
PR2
PR2
 
Messages: 278
Inscription: Mer Sep 06, 2006 8:44 am
Localisation: Carcassonne (France)

Messagede BalHack » Lun Mar 31, 2008 12:30 pm

Salut, voilà, le template propre
Il n'y a que la cellule qui contient la date qui n'est pas fixe, il faut juste lui donner une taille

Code: Tout sélectionner
<!-- BEGIN forumrow -->
   <!-- IF (forumrow.S_IS_CAT and not forumrow.S_FIRST_ROW) or forumrow.S_NO_CAT  -->
</table>
<br />
   <!-- ENDIF -->
   <!-- IF forumrow.S_IS_CAT or forumrow.S_FIRST_ROW  or forumrow.S_NO_CAT  -->

      <table class="tablebg" cellspacing="1" width="100%">

<tr>
   <th colspan="2">&nbsp;{L_FORUM}&nbsp;</th>
   <th width="50">&nbsp;{L_TOPICS}&nbsp;</th>
   <th width="50">&nbsp;{L_POSTS}&nbsp;</th>
   <th>&nbsp;{L_LAST_POST}&nbsp;</th>
</tr>
               <!-- IF forumrow.S_IS_CAT -->
      <tr>
         <td class="cat" colspan="2"><h4><a href="{forumrow.U_VIEWFORUM}">{forumrow.FORUM_NAME}</a></h4></td>
         <td class="catdiv" colspan="3">&nbsp;</td>
      </tr>
      <!-- ENDIF -->
   <!-- ENDIF -->

      <!-- IF not forumrow.S_IS_CAT -->
      <tr>
         <td class="row1" width="50" align="center">{forumrow.FORUM_FOLDER_IMG}</td>
         <td class="row1" width="100%">
            <!-- IF forumrow.FORUM_IMAGE -->
               <div style="float: {S_CONTENT_FLOW_BEGIN}; margin-{S_CONTENT_FLOW_END}: 5px;">{forumrow.FORUM_IMAGE}</div><div style="float: {S_CONTENT_FLOW_BEGIN};">
            <!-- ENDIF -->
            <a class="forumlink" href="{forumrow.U_VIEWFORUM}">{forumrow.FORUM_NAME}</a>
            <p class="forumdesc">{forumrow.FORUM_DESC}</p>
            <!-- IF forumrow.MODERATORS -->
               <p class="forumdesc"><strong>{forumrow.L_MODERATOR_STR}:</strong> {forumrow.MODERATORS}</p>
            <!-- ENDIF -->
            <!-- IF forumrow.SUBFORUMS -->
               <p class="forumdesc"><strong>{forumrow.L_SUBFORUM_STR}</strong> {forumrow.SUBFORUMS}</p>
            <!-- ENDIF -->
            <!-- IF forumrow.FORUM_IMAGE --></div><!-- ENDIF -->
         </td>
         <td class="row2" align="center"><p class="topicdetails">{forumrow.TOPICS}</p></td>
         <td class="row2" align="center"><p class="topicdetails">{forumrow.POSTS}</p></td>
         <td class="row2" align="center" nowrap="nowrap">
            <!-- IF forumrow.LAST_POST_TIME -->
               <p class="topicdetails">{forumrow.LAST_POST_TIME}</p>
               <p class="topicdetails">{forumrow.LAST_POSTER_FULL}
                  <a href="{forumrow.U_LAST_POST}">{LAST_POST_IMG}</a>
               </p>
   <!-- ENDIF -->
         
   <!-- ENDIF -->
                              </td>
   </tr>

<!-- BEGINELSE -->


<!-- END forumrow -->

         <table class="tablebg" cellspacing="1" width="100%">
<tr>
   <td class="cat" colspan="5" align="{S_CONTENT_FLOW_END}"><!-- IF not S_IS_BOT and U_MARK_FORUMS --><a class="nav" href="{U_MARK_FORUMS}">{L_MARK_FORUMS_READ}</a><!-- ENDIF -->&nbsp;</td>
</tr>
</table>
BalHack
 
Messages: 2
Inscription: Lun Mar 31, 2008 12:28 pm

Messagede landry » Lun Mar 31, 2008 3:58 pm

Bonjour BalHack,

J'ai testé et effectivement c'est parfait, cela régle le problème de l'affichage érronnée des catégories.

Juste une petite modif à ajouter si le MOD no duplicate est installé.
landry
PR2
PR2
 
Messages: 278
Inscription: Mer Sep 06, 2006 8:44 am
Localisation: Carcassonne (France)


Retourner vers Le Forum phpBB

 


  • Articles en relation
    Réponses
    Vus
    Dernier message

Qui est en ligne

Utilisateurs parcourant ce forum: Aucun utilisateur enregistré et 22 invités