CSSActif, le forum, n'est plus maintenu. Il est néanmoins disponible pour consultation. Pour des outils pratiques, rendez-vous sur: Découvrez CSSActif, une collection d'outils et de tutoriels interactifs pour les développeurs Web — HTML, CSS, JavaScript et bien plus! | | Tutorial "Encadrer chacun de vos forums de façon originale" qui ne marche pas [résolu] | |
| Berserck
{ Membre }
Messages : 42
| Bonjour ! Voilà, j'ai réalisé le tutorial Encadrer chacun de vos forums de façon originale sur un de mes Forums test, mais voilà : ça ne marche pas :/ ! J'ai relu le tutorial, vérifié chaque étape, et je n'ai rien repérer comme fautes. J'ai bien séparé les catégories sur l'index, mit la largeur de mon forum à 900... Mais rien... Donc bon, je vous donne les codes concernés (Index_box et le css...) Index_box : - Code:
-
<table width="100%" border="0" cellspacing="1" cellpadding="0" align="center"> <tr> <td valign="bottom"> <!-- BEGIN switch_user_logged_in --> <span class="gensmall">{LAST_VISIT_DATE}<br /> {CURRENT_TIME}<br /> </span> <!-- END switch_user_logged_in --> <div class="nav"><a class="nav" href="{U_INDEX}">{L_INDEX}</a>{NAV_CAT_DESC}</div> </td> <td class="gensmall" align="right" valign="bottom"> <!-- BEGIN switch_user_logged_in --> <a class="gensmall" href="{U_SEARCH_NEW}">{L_SEARCH_NEW}</a><br /> <a class="gensmall" href="{U_SEARCH_SELF}">{L_SEARCH_SELF}</a><br /> <!-- END switch_user_logged_in --> <a class="gensmall" href="{U_SEARCH_UNANSWERED}">{L_SEARCH_UNANSWERED}</a> </td> </tr> </table> <!-- BEGIN catrow --><!-- BEGIN tablehead --><!-- Début de l'ajout du haut --> <div class="ajout_haut"></div> <!-- Fin de l'ajout du haut --><table class="forumline" width="100%" border="0" cellspacing="1" cellpadding="0"> <tr> <th colspan="{catrow.tablehead.INC_SPAN}" nowrap="nowrap" width="100%" class="secondarytitle"> {catrow.tablehead.L_FORUM} </th> <th nowrap="nowrap" width="50">{L_TOPICS}</th> <th nowrap="nowrap" width="50">{L_POSTS}</th> <th nowrap="nowrap" width="150"><div style="width:150px;">{L_LASTPOST}</div></th> </tr> <!-- END tablehead --> <!-- BEGIN cathead --> <tr> <!-- BEGIN inc --> <td class="{catrow.cathead.inc.INC_CLASS}" width="46"><img src="{SPACER}" height="0" width="46" /></td> <!-- END inc --> <td class="{catrow.cathead.CLASS_CAT}" colspan="{catrow.cathead.INC_SPAN}" width="100%"> <h{catrow.cathead.LEVEL} class="hierarchy"> <span class="cattitle"> <a class="cattitle" title="{catrow.cathead.CAT_DESC}" href="{catrow.cathead.U_VIEWCAT}">{catrow.cathead.CAT_TITLE}</a> </span> </h{catrow.cathead.LEVEL}> </td> <td class="{catrow.cathead.CLASS_ROWPIC}" colspan="3" align="right"> </td> </tr> <!-- END cathead --> <!-- BEGIN forumrow --> <tr> <!-- BEGIN inc --> <td class="{catrow.forumrow.inc.INC_CLASS}" width="46"><img src="{SPACER}" height="0" width="46" alt="." /></td> <!-- END inc --> <td class="{catrow.forumrow.INC_CLASS}" align="center" valign="middle"> <img title="{catrow.forumrow.L_FORUM_FOLDER_ALT}" src="{catrow.forumrow.FORUM_FOLDER_IMG}" alt="{catrow.forumrow.L_FORUM_FOLDER_ALT}" /> </td> <td class="row1 over" colspan="{catrow.forumrow.INC_SPAN}" valign="top" width="100%" height="50"> <h{catrow.forumrow.LEVEL} class="hierarchy"> <span class="forumlink"> <a class="forumlink" href="{catrow.forumrow.U_VIEWFORUM}">{catrow.forumrow.FORUM_NAME}</a><br /> </span> </h{catrow.forumrow.LEVEL}> <span class="genmed">{catrow.forumrow.FORUM_DESC}</span> <span class="gensmall"> <!-- BEGIN switch_moderators_links --> {catrow.forumrow.switch_moderators_links.L_MODERATOR}{catrow.forumrow.switch_moderators_links.MODERATORS} <!-- END switch_moderators_links --> {catrow.forumrow.L_LINKS}{catrow.forumrow.LINKS} </span> </td> <td class="row3" 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="row3 over" align="center" valign="middle" height="50"> <span class="gensmall">{catrow.forumrow.LAST_POST}</span> </td> </tr> <!-- END forumrow --> <!-- BEGIN catfoot --> <tr> <!-- BEGIN inc --> <td class="{catrow.catfoot.inc.INC_CLASS}" width="46"><img src="{SPACER}" height="0" width="46" /></td> <!-- END inc --> <td class="spaceRow" colspan="{catrow.catfoot.INC_SPAN}" height="1"><img src="{SPACER}" alt="" height="1" width="1" /></td> </tr> <!-- END catfoot --> <!-- BEGIN tablefoot --> </table><!-- Début de l'ajout du bas --> <div class="ajout_bas"></div> <!-- Fin de l'ajout du bas --><img src="{SPACER}" alt="" height="5" width="1" /><!-- END tablefoot --><!-- END catrow --> Code CSS ajouté suite au tutorial : - Code:
-
/* tableau autour forum BEGIN */ .ajout_haut { background-color: transparent; background-image: url('http://nsa10.casimages.com/img/2010/01/14/100114065535545189.png') center top no-repeat; width: 900px; height: 26px; border: none; }
.ajout_bas { background-color: transparent; background-image: url('http://nsa11.casimages.com/img/2010/01/14/100114065612568113.png') center top no-repeat; width: 900px; height: 26px; border: none; }
.forumline { background-color: transparent; background-image: url('http://nsa10.casimages.com/img/2010/01/14/100114070515465818.png') center repeat-y; padding: 3px; /* Il vaut mieux ajouter quelques pixels de marge intérieure, sinon le forum est collé à l'image intérieure, et ça ne rend pas bien. Faites le test sinon !*/ border: none; } /* tableau autour forum END */ Voilà, je ne vois vraiment pas où j'ai fais une erreur :/... Je suis sûre que c'est un truc tout bête en plus x) Bonne soirée en tout cas !!! |
Dernière édition par Berserck le Mer 20 Juin 2012, 17:44, édité 1 fois | |
| | | Doare
{ Spécialiste }
Messages : 544
| Merf. Il va falloir corriger quelque chose dans ce tutoriel... Pour tous les background-image que tu as déterminés, tu as défini plusieurs propriétés à la fois. Du coup ça ne marche pas. Je m'explique... - Code:
-
.ajout_haut { background-color: transparent; background-image: url('http://nsa10.casimages.com/img/2010/01/14/100114065535545189.png') center top no-repeat; } "center top" et "no-repeat" appartiennent à deux propriétés différentes, respectivement "background-position" et "background-repeat". Elles font partie d'un groupe de propriétés (dont fait partie "background-color", bien déterminé tout seul) qu'il est possible de définir en une seule fois, tel que c'est fait à tort dans le "background-image". Dans ce cas-là, il faut utiliser la propriété "background", en respectant l'ordre suivant : - Code:
-
.class { background:color image repeat attachment position; } En somme, tu devrais avoir soit : - Code:
-
.ajout_haut { background-color: transparent; background-image: url('http://nsa10.casimages.com/img/2010/01/14/100114065535545189.png'); background-repeat: no-repeat; background-position: center top; } Soit : - Code:
-
.ajout_haut { background: transparent url('http://nsa10.casimages.com/img/2010/01/14/100114065535545189.png') no-repeat center top; } Bref. Ce n'est pas vraiment ta faute, c'est le tuto qui est erroné sur la propriété en question. Normalement, une fois que tu as corrigé les passages concernés, ça devrait marcher. | | |
| | | Berserck
{ Membre }
Messages : 42
| Ho en effet tout est rentré dans l'ordre !!! Merci beaucoup en tout cas (je note bien la différence entre les deux méthodes de codage, ça me servira encore je pense) ! Passe une bonne soirée ^^ | | |
| | | Psycho
Psychopathe
Messages : 3407
| Hello (: Je vois que le problème est résolu, par conséquent je classe ! Merci de l'avoir signalé | | |
| | | Contenu sponsorisé
| | | | | Tutorial "Encadrer chacun de vos forums de façon originale" qui ne marche pas [résolu] | |
|
Sujets similaires | |
|
| Permission de ce forum: | Vous ne pouvez pas répondre aux sujets dans ce forum
| |
| |
| |
|
| Partenaires Or
|
|