Problème CSS avec le menu

Résolu
JeffCky -  
 JeffCky -
Bonjour, je suis un tutoriel pour faire mon site, je suis au CSS et lorsque je centre (Haut=>Milieu=>Bas, PAS Droite=>Milieu=>Bas) ben l'image du menu se répète plus bas :
http://www.hostingpics.net/viewer.php?id=539474Untitled_1.jpg
(j'utilise le code padding-top: 40px;)

12 réponses

  1. notobe Messages postés 2222 Statut Membre 213
     
    Sans le code complet, ou une url, ce n'est pas facile de dire grand chose...
    0
  2. JeffCky
     
    #menu
    {
    background-image: url("../site/images/haut.jpg");
    background-repeat:none;
    width: 1000px;
    height: 161px;
    text-align: center;
    font-size: 16px;
    padding-top: 40px;
    }
    0
    1. notobe Messages postés 2222 Statut Membre 213
       
      Quand je disais code complet, c'est html + CSS ;)
      0
  3. JeffCky
     
    Comment je peux vous les faire parvenir ?
    0
    1. notobe Messages postés 2222 Statut Membre 213
       
      Si le site n'est pas en ligne, copier aussi le code html ici.
      0
  4. JeffCky
     
    CSS :
    body
    {
    background-color: #6a3737;
    }
    #header
    {
    background-image: url("../site/images/banniere.jpg");
    width: 1000px;
    height: 255px;
    }

    #menu
    {
    background-image: url("../site/images/haut.jpg");
    background-repeat:none;
    width: 1000px;
    height: 161px;
    text-align: center;
    font-size: 16px;
    padding-top: 40px;
    }

    #corps
    {
    background-image: url("../site/images/milieu.jpg");
    background-repeat: repeat-y;
    width: 1000px;
    }
    #footer
    {
    background-image: url("../site/images/bas.jpg");
    width: 1000px;
    height: 85px;
    }
    #conteneur
    {
    margin: auto;
    width: 778px;
    }

    #menu a
    {
    color: white;
    margin-left: 10px;
    margin-right: 10px;
    }

    HTML :
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr" >
    <head>
    <title>JeffCky Website</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <link rel="stylesheet" media="screen" type="text/css" href="index.css" />
    </head>
    <body>
    <div id="conteneur">
    <div id="header"></div>
    <div id="menu">
    <a href='index.html'>Accueil</a> <a href='index.html'>News</a> <a href='index.html'>Guestbook</a></div>
    <div id="corps"></div>
    <div id="corps">
    Blablablablalbalblablalbal Blablablablalbalblablalbal
    Blablablablalbalblablalbal Blablablablalbalblablalbal
    Blablablablalbalblablalbal Blablablablalbalblablalbal
    Blablablablalbalblablalbal Blablablablalbalblablalbal
    Blablablablalbalblablalbal Blablablablalbalblablalbal
    Blablablablalbalblablalbal Blablablablalbalblablalbal
    Blablablablalbalblablalbal Blablablablalbalblablalbal
    Blablablablalbalblablalbal Blablablablalbalblablalbal
    Blablablablalbalblablalbal Blablablablalbalblablalbal
    </div>
    <div id="footer">
    Jeffcky Copyright - Tous droits réservés © 2010
    </div>
    </body>
    </html>
    0
    1. notobe Messages postés 2222 Statut Membre 213
       
      C'est normal le doublon <div id="corps"> ? Surtout qu'un id ne peut servir qu'une seule fois normalement...
      0
  5. Vous n’avez pas trouvé la réponse que vous recherchez ?

    Posez votre question
  6. JeffCky
     
    Où ?
    0
    1. JeffCky
       
      Je veux dire, je dois changé quoi ?
      0
    2. notobe Messages postés 2222 Statut Membre 213
       
      <a href='index.html'>Accueil</a> <a href='index.html'>News</a> <a href='index.html'>Guestbook</a></div>
      <div id="corps"></div>
      <div id="corps">
      Blablablablalbalblablalbal Blablablablalbalblablalbal 
      0
    3. notobe Messages postés 2222 Statut Membre 213
       
      Il faut l'enlever.
      0
  7. JeffCky
     
    Ben je l'ai fait, mais sa ne change pas :s
    0
    1. notobe Messages postés 2222 Statut Membre 213
       
      Je n'arrive pas à reproduire le phénomène, mais évidemment, je n'ai pas les images... donc.
      Cela dit, une autre erreur : ce n'est pas background-repeat:none, mais background-repeat:no-repeat.
      Ou plus simplement :
      background: url("../site/images/milieu.jpg") no-repeat; 
      0
  8. JeffCky
     
    Ben il ne l'a plus si je met ca
    0
    1. notobe Messages postés 2222 Statut Membre 213
       
      Tu as bien enlevé le suffixe -image ?
      0
  9. JeffCky
     
    Sufixe image ?
    0
    1. notobe Messages postés 2222 Statut Membre 213
       
      enlever le -image de background-image
      0
  10. JeffCky
     
    Sa ne change pas
    0
    1. notobe Messages postés 2222 Statut Membre 213
       
      Tu pourrais la mettre en ligne cette page ?
      0
  11. JeffCky
     
    Je l'ai mise sur atspace, mais il bug, il dit que le chargement a échouer
    0
    1. notobe Messages postés 2222 Statut Membre 213
       
      Bon...

      Mets tes images à télécharger quelque part que je puisse les récupérer.
      Quel doctype as-tu utilisé ? Ce phénomène se produit-il sur tous les navigateurs ?
      0
  12. JeffCky
     
    http://www.hostingpics.net/viewer.php?id=825887banniere.jpg
    http://www.hostingpics.net/viewer.php?id=737675bas.jpg
    http://www.hostingpics.net/viewer.php?id=120948haut.jpg
    http://www.hostingpics.net/viewer.php?id=351254milieu.jpg
    http://jeffcky.atspace.com/
    Je ne sais pas qu'elle doctype j'ai utiliser :/
    0
    1. notobe Messages postés 2222 Statut Membre 213
       
      Et c'est c'est en ligne finalement ! cool... :)
      C'est du xhtml 1.0 Strict ton doctype...

      Pas très judicieux le choix de tes images, mais bon, la solution :

      code CSS
      #menu   
      {  
      background: url("haut.jpg") no-repeat;  
      width: 1000px;  
      height: 161px;  
      text-align: center;  
      font-size: 16px;  
      }  
      #menu p {  
      margin:0;  
      line-height:100px;  
      }


      Code html du menu :
      <div id="menu">  
      <p><a href='index.html'>Accueil</a> <a href='index.html'>News</a> <a href='index.html'>Guestbook</a></p></div> 
      0
  13. JeffCky
     
    Merciii !!!!!

    "Pas très judicieux le choix de tes images, mais bon, la solution : "
    C'est juste un premier essaie !
    Merci beaucouuuuuuuuuuuuuuuuuuuup !
    0