Forum |  HardWare.fr | News | Articles | PC | S'identifier | S'inscrire | Shop Recherche
1256 connectés 

  FORUM HardWare.fr
  Programmation
  HTML/CSS

  Problème d'alignement CSS dans les balises

 


 Mot :   Pseudo :  
 
Bas de page
Auteur Sujet :

Problème d'alignement CSS dans les balises

n°1897101
alx067
Posté le 19-06-2009 à 18:55:16  profilanswer
 

Bonsoir, je crée actuellement un site web avec une mise en page CSS.
 
Sous IE7 tout fonctionne à merveille, depuis quelques jours IE8 me mets un décalage de l'image... (pareil pour Firefox 3).
 
Je ne sais pas comment résoudre ce problème...
 
Voici l'image et les codes correspondants...
 
http://contactartisia.free.fr/artisia.jpg
 
Fichier PHP :

Code :
  1. (...)
  2. <script type="text/javascript"></script>
  3. <style type="text/css" title="currentStyle" media="screen">
  4.  @import "style/style.css";
  5. </style>
  6.     <style type="text/css">body {
  7. }
  8. </style></head>
  9. <body id="css-zen-garden">
  10. <div id="container">
  11. <div id="intro">
  12.  <div id="pageHeader">
  13.                  <h1><span></span></h1>
  14.      <h2><span></span></h2>
  15.                              (...)
  16.  <div id="quickSummary">
  17.   <p class="p1"><span></span></p>
  18.   <p class="p2"><span></span></p>
  19.  </div>
  20.  <div id="preamble">
  21.      <p class="p3"><span>(...)</span></p>
  22.      <p class="p4">(...)</p>
  23.    <hr />
  24.  </div>
  25. </div>
  26. <div id="supportingText">
  27.   <div id="benefits">
  28.                   (...)
  29.                </div>
  30. </div>
  31. </body>
  32. </html>


 
Fichier CSS :

Code :
  1. (...)
  2. /*===================
  3.     body elements
  4. ===================*/
  5. #container {
  6. position:absolute;
  7. width:790px;
  8. left:50%;
  9. margin-left:-395px;
  10. }
  11. #pageHeader {
  12. background:url(banner.gif) no-repeat top center;
  13. width:278px;
  14. height:185px;
  15. }
  16. #pageHeader h1, #pageHeader h2 {
  17. display:none;
  18. }
  19. #quickSummary {
  20. background:url(bg_header.gif) repeat-y;
  21. height:20px;
  22. }
  23. #quickSummary p{
  24. display:none;
  25. }
  26. #preamble {
  27. width:600px;
  28. background:url(bg_repeater.gif) repeat-y;
  29. padding:25px 45px 0px 35px;
  30. voice-family: "\"}\"";
  31. voice-family:inherit;
  32. width:520px;
  33. }
  34. #preamble h3 {
  35. display:none;
  36. }
  37. #preamble h3 span {
  38. visibility:hidden;
  39. }
  40. #preamble p.p1 {
  41. padding-left:30px;
  42. padding-right:30px;
  43. line-height:1.2em;
  44. font-style:italic;
  45. font-size:12pt;
  46. font-family: Monotype Corsiva, Palatino, Georgia, Times New Roman, serif;
  47. font-weight: bold;
  48. }
  49. #preamble p.p2 {
  50. /* background:url(preamble.gif) no-repeat top center;  */
  51. /* padding-top:150px;  */
  52. padding-top:15px;
  53. }
  54. #preamble p.p3 {
  55. padding-left:30px;
  56. padding-right:30px;
  57. line-height:1.2em;
  58. font-style:italic;
  59. font-size:18pt;
  60. font-family: Monotype Corsiva, Palatino, Georgia, Times New Roman, serif;
  61. font-weight: bold;
  62. }
  63. #preamble p.p4 {
  64. padding-left:30px;
  65. padding-right:30px;
  66. line-height:1.2em;
  67. font-style:italic;
  68. font-size:14pt;
  69. font-family: Monotype Corsiva, Palatino, Georgia, Times New Roman, serif;
  70. font-weight: bold;
  71. }
  72. #supportingText{
  73. width:600px;
  74. background:url(bg_repeater.gif) repeat-y;
  75. }
  76. #supportingText h3 {
  77. text-align:center;
  78. padding:0;
  79. margin:0;
  80. background:no-repeat center;
  81. height:25px;
  82. }
  83. #supportingText h3 span {
  84. visibility:hidden;
  85. }
  86. #benefits {
  87. padding-left:35px;
  88. padding-right:45px;
  89. text-align: center;
  90. }
  91. #benefits h3 {
  92. /* background-image:url(benefits.gif);  */
  93. (...)


 
 
Merci...


Message édité par alx067 le 27-06-2009 à 08:38:37
mood
Publicité
Posté le 19-06-2009 à 18:55:16  profilanswer
 

n°1897107
alx067
Posté le 19-06-2009 à 19:02:36  profilanswer
 

J'oubliais...
 
Chose étrange, en passant par l'adresse de mon hébergeur (Free) et IE7, il n'y a pas de problème...
En passant par l'adresse de redirection (nom-domaine.fr) et IE7, il y a un décalage.
 
J'ai essayé un joignant la feuille de style CSS avec ce code:

Code :
  1. <link href="style/style.css" rel="stylesheet" type="text/css" media="all" />


 
Le problème reste identique...


Message édité par alx067 le 19-06-2009 à 19:02:53
n°1897868
alx067
Posté le 22-06-2009 à 23:22:13  profilanswer
 

Up !

n°1897890
phosphorel​oaded
Posté le 23-06-2009 à 02:13:41  profilanswer
 

Bonjour,

 

le problème ça pourrait être la redirection plutôt que ton site:

Code :
  1. <html><head>
  2. </head><frameset cols="*" border="0" framespacing="0" frameborder="no">
  3.   <frame src="http://###.free.fr" name="page" marginwidth="0" marginheight="0" scrolling="auto">
  4. </frameset>
  5. </html>


S'il y avait un frameset, est-ce que ça fonctionnerait mieux? J'utilise jamais les frames donc je laisse la conclusion à d'autres mais une frame en mode standard dans une page en mode quirks ça me laisse un mauvais pressentiment ...


Message édité par phosphoreloaded le 23-06-2009 à 02:14:44
n°1899284
alx067
Posté le 25-06-2009 à 20:31:22  profilanswer
 

Bonsoir, j'ai réécris le code de A à Z est le problème est toujours le même.
 
Voici les codes

Code :
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr" lang="fr">
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  5. <title><?php include("coordonnees/nom_de_l_entreprise.txt" ); ?></title>
  6. <link href="style/restyle.css" rel="stylesheet" type="text/css" media="all" />
  7. </head>
  8. <body>
  9. <div id="contenant">
  10.   <div id="balise_gauche">
  11.     <img src="style/logo_inscrustation.gif" width="64" height="140" />
  12.     <img src="style/logo_reduit.gif" alt="<?php include("coordonnees/nom_de_l_entreprise.txt" ); ?>" width="150" height="140" />
  13.   </div>
  14.  
  15.   <div id="haut_de_page">
  16.   </div>
  17.  
  18.   <div id="titre">
  19.     <p class="p3"><?php include("coordonnees/nom_de_l_entreprise.txt" ); ?></p>
  20.     <p class="p4"><?php include("coordonnees/devise_de_l_entreprise.txt" ); ?></p>
  21.   </div>
  22.  
  23.   <div id="corps_de_texte">
  24.     <p>Texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte.</p>
  25.   </div>
  26.  
  27. </div>
  28. </body>
  29. </html>


 

Code :
  1. @charset "utf-8";
  2. /* CSS Document */
  3. body {
  4. font: 10.5pt Palatino, Georgia, Times New Roman, serif;
  5. color:#554;
  6. font-weight:500;
  7. text-align:left;
  8. margin:0;
  9. padding:0;
  10. background-image: url(fond.png);
  11. background-repeat: no-repeat;
  12. background-color: #fd5121;
  13. }
  14. a:link, a:visited, a:active {
  15. font-style:italic;
  16. color:black;
  17. font-weight:300;
  18. text-decoration:none;
  19. }
  20. a:hover {
  21. font-style:italic;
  22. color:#B8860B;
  23. text-decoration:underline;
  24. }
  25. /* Body Element */
  26. #contenant {
  27. position:absolute;
  28. left:50%;
  29. width:800px;
  30. margin-left:-400px;
  31. }
  32. div#balise_gauche {
  33. background:url(etiquette.gif) no-repeat top center;
  34. width:278px;
  35. height:185px;
  36. }
  37. #balise_droite {
  38. position:absolute;
  39. width:235px;
  40. height:199px;
  41. }
  42. div#haut_de_page {
  43. background:url(haut_de_page.gif) repeat-y;
  44. height:20px;
  45. }
  46. div#titre {
  47. background:url(feuille.gif) repeat-y;
  48. padding:25px 45px 0px 35px;
  49. width:520px;
  50. }
  51. #titre p.p3 {
  52. padding-left:30px;
  53. padding-right:30px;
  54. line-height:1.2em;
  55. font-style:italic;
  56. font-size:18pt;
  57. font-family: Monotype Corsiva, Palatino, Georgia, Times New Roman, serif;
  58. font-weight: bold;
  59. text-align: center;
  60. }
  61. #titre p.p4 {
  62. padding-left:30px;
  63. padding-right:30px;
  64. line-height:1.2em;
  65. font-style:italic;
  66. font-size:14pt;
  67. font-family: Monotype Corsiva, Palatino, Georgia, Times New Roman, serif;
  68. font-weight: bold;
  69. text-align: center;
  70. }
  71. div#corps_de_texte {
  72. position:absolute;
  73. background:url(feuille.gif) repeat-y;
  74. padding-left:35px;
  75. padding-right:245px;
  76. text-align: center;
  77. width:520px;
  78. }


 
http://contactartisia.free.fr/artisia2.jpg
 
Toujours ce décalage...


Message édité par alx067 le 25-06-2009 à 20:33:34
n°1899288
alx067
Posté le 25-06-2009 à 21:02:25  profilanswer
 

Ok problème résolu : Il fallait rajouter le ligne de code margin-top:0px;
 

Code :
  1. @charset "utf-8";
  2. /* CSS Document */
  3. body {
  4. font: 10.5pt Palatino, Georgia, Times New Roman, serif;
  5. color:#554;
  6. font-weight:500;
  7. text-align:left;
  8. margin:0;
  9. padding:0;
  10. background-image: url(fond.png);
  11. background-repeat: no-repeat;
  12. background-color: #fd5121;
  13. }
  14. a:link, a:visited, a:active {
  15. font-style:italic;
  16. color:black;
  17. font-weight:300;
  18. text-decoration:none;
  19. }
  20. a:hover {
  21. font-style:italic;
  22. color:#B8860B;
  23. text-decoration:underline;
  24. }
  25. /* Body Element */
  26. #contenant {
  27. position:absolute;
  28. left:50%;
  29. width:800px;
  30. margin-left:-400px;
  31. }
  32. div#balise_gauche {
  33. background:url(etiquette.gif) no-repeat top center;
  34. width:278px;
  35. height:185px;
  36. }
  37. #balise_droite {
  38. position:absolute;
  39. width:235px;
  40. height:199px;
  41. }
  42. div#haut_de_page {
  43. background:url(haut_de_page.gif) repeat-y;
  44. height:20px;
  45. }
  46. div#titre {
  47. background:url(feuille.gif) repeat-y;
  48. padding:25px 45px 0px 35px;
  49. width:520px;
  50. }
  51. #titre p.p3 {
  52. padding-left:30px;
  53. padding-right:30px;
  54. line-height:1.2em;
  55. font-style:italic;
  56. font-size:18pt;
  57. font-family: Monotype Corsiva, Palatino, Georgia, Times New Roman, serif;
  58. font-weight: bold;
  59. text-align: center;
  60. }
  61. #titre p.p4 {
  62. padding-left:30px;
  63. padding-right:30px;
  64. line-height:1.2em;
  65. font-style:italic;
  66. font-size:14pt;
  67. font-family: Monotype Corsiva, Palatino, Georgia, Times New Roman, serif;
  68. font-weight: bold;
  69. text-align: center;
  70. }
  71. div#corps_de_texte {
  72. margin-top:0px;
  73. position:absolute;
  74. background:url(feuille.gif) repeat-y;
  75. padding-left:35px;
  76. padding-right:245px;
  77. padding-top:20px;
  78. text-align: center;
  79. width:520px;
  80. }
  81. div#bas_de_page {
  82. position:relative;
  83. background:url(feuille.gif) repeat-y;
  84. padding-left:35px;
  85. padding-right:245px;
  86. text-align: center;
  87. width:520px;
  88. }


Message édité par alx067 le 25-06-2009 à 21:03:31
n°1899289
alx067
Posté le 25-06-2009 à 21:16:06  profilanswer
 

Il existe toujours une marge sous FF3...
 
 :cry:


Message édité par alx067 le 25-06-2009 à 23:40:45
n°1899368
phosphorel​oaded
Posté le 26-06-2009 à 10:55:48  profilanswer
 

Tu n'as pas donné l'URL ... même si on peut la trouver facilement.
 
Vire ce <hr /> qui a une marge. Si tu veux faire un trait, utilise border-top ou bottom ou bien un background positionné en bas ou en haut selon l'élément auquel tu l'appliques

n°1899383
alx067
Posté le 26-06-2009 à 11:21:51  profilanswer
 

le <hr /> n'y est pour rien, j'ai tenté de le virer dans aucun effet (la marge est encore plus grande (toujours sous FF3)...)
Adresse web : http://modelephp.free.fr/

Message cité 1 fois
Message édité par alx067 le 26-06-2009 à 11:25:12
n°1899407
David Bori​ng
Posté le 26-06-2009 à 11:46:08  profilanswer
 

c'est le margin par défaut de #titre p.p4
tu dois donc mettre margin-bottom:0
 
Et du dois surtout remplacer ce p par un titre (hx)

mood
Publicité
Posté le 26-06-2009 à 11:46:08  profilanswer
 

n°1899425
alx067
Posté le 26-06-2009 à 12:24:51  profilanswer
 

Merci ! C'est le margin-bottom:0; dans le titre qui posé problème...
 
Par contre j'ai pas compris l'histoire du hx ???
 
Même sur le http://www.siteduzero.com j'avais pas trouvé...
 
Merci David Borring :bounce:


Message édité par alx067 le 26-06-2009 à 12:27:10
n°1899430
David Bori​ng
Posté le 26-06-2009 à 12:48:37  profilanswer
 

le x est là pour remplacer un chiffre de 1 à 6
artista devait être un h1 et C'est un peu l'âme du monde un h2

n°1899671
alx067
Posté le 27-06-2009 à 08:33:00  profilanswer
 

lol J'ai compris pour le hx.
 
En revanche j'ai ajouté le menu qui me pose à nouveau décalage sous IE8, j'ai à nouveau un décalage...
 

Code :
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr" lang="fr">
  3. <head>
  4. <?php include("textes_et_mise_en_page/meta.txt" ); ?>
  5. <!-- Inspiré de CSS Garden (http://www.csszengarden.com/tr/francais) -->
  6. <title><?php include("coordonnees/nom_de_l_entreprise.txt" ); ?> - Accueil</title>
  7. <link href="style/restyle.css" rel="stylesheet" type="text/css" media="all" />
  8. </head>
  9. <body>
  10. <div id="contenant">
  11.   <div id="balise_gauche">
  12.     <img src="style/logo_inscrustation.gif" width="64" height="140" />
  13.     <img src="style/logo_reduit.gif" alt="<?php include("coordonnees/nom_de_l_entreprise.txt" ); ?>" width="150" height="140" />
  14.   </div>
  15.  
  16.   <div id="haut_de_page">
  17.   </div>
  18.  
  19.   <div id="menu">
  20.     <div id="menu_haut"></div>
  21.    
  22.     <div id="menu_centre" class="menu">
  23.     <p><a href="index.php" target="_self" title="Retour en page principale">Accueil</a></p>
  24.     <p>&nbsp;</p>
  25.     <p><a href="nouveautes.php" target="_self" title="Voir les nouveaut&eacute;s">Nouveaut&eacute;s</a></p>
  26.     <p>&nbsp;</p>
  27.     <p><a href="catalogue/album/index.html" target="_blank" title="Visionner tous les produits">Catalogue</a></p>
  28.     <p>&nbsp;</p>
  29.     <p><a href="identification.php" target="_self" title="S'identifier">Identification</a></p>
  30.     <p><a href="modification.php" target="_self" title="Modifier ses coordonn&eacute;es">Modification</a></p>
  31.     <p><a href="creation.php" target="_self" title="Cr&eacute;er votre compte">Nouveau un compte</a></p>
  32.     <p><a href="mot_de_passe_oublie.php" target="_self" title="Modifier ses coordonn&eacute;es">Mot de passe oubli&eacute;</a></p>
  33.     <p>&nbsp;</p>
  34.     <p><a href="#" target="_self" title="">Passer une commande</a></p>
  35.     <p><a href="#" target="_self" title="">Enregistrer un panier</a></p>
  36.     <p><a href="#" target="_self" title="">Visualiser mes paniers</a></p>
  37.     <p><a href="#" target="_self" title="">Suivi de commande</a></p>
  38.     <p>&nbsp;</p>
  39.     <p><a href="#" target="_self" title="">Contactez-nous</a></p>
  40.     <p><a href="#" target="_self" title="">Voyager en Inde</a></p>
  41.     <p>&nbsp;</p>
  42.     </div>
  43.    
  44.     <div id="menu_bas"></div>
  45.   </div>
  46.  
  47.   <div id="titre">
  48.     <p class="p3"><?php include("coordonnees/nom_de_l_entreprise.txt" ); ?></p>
  49.     <p class="p4"><?php include("coordonnees/devise_de_l_entreprise.txt" ); ?></p>
  50.     <br />
  51.     <hr />
  52.   </div>
  53.  
  54.   <div id="corps_de_texte">
  55.     <p>Texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte texte.</p>
  56.   </div>
  57.  
  58. </div>
  59. </body>
  60. </html>


 

Code :
  1. /* CSS Document */
  2. body {
  3. font: 10.5pt Palatino, Georgia, Times New Roman, serif;
  4. color:#554;
  5. font-weight:500;
  6. text-align:left;
  7. margin:0;
  8. padding:0;
  9. background-image: url(fond.png);
  10. background-repeat: no-repeat;
  11. background-color: #fd5121;
  12. }
  13. a:link, a:visited, a:active {
  14. font-style:italic;
  15. color:black;
  16. font-weight:300;
  17. text-decoration:none;
  18. }
  19. a:hover {
  20. font-style:italic;
  21. color:#B8860B;
  22. text-decoration:underline;
  23. }
  24. /* Body Element */
  25. #contenant {
  26. position:absolute;
  27. left:50%;
  28. width:800px;
  29. margin-left:-400px;
  30. }
  31. div#balise_gauche {
  32. background:url(etiquette.gif) no-repeat top center;
  33. width:278px;
  34. height:185px;
  35. }
  36. #balise_droite {
  37. position:absolute;
  38. width:235px;
  39. height:199px;
  40. }
  41. div#haut_de_page {
  42. background:url(haut_de_page.gif) repeat-y;
  43. height:20px;
  44. margin-bottom:0px;
  45. }
  46. div#titre {
  47. background:url(feuille.gif) repeat-y;
  48. padding:20px 45px 0px 35px;
  49. width:520px;
  50. height:130px;
  51. }
  52. #titre p.p3 {
  53. padding-left:30px;
  54. padding-right:30px;
  55. line-height:1.2em;
  56. font-style:italic;
  57. font-size:18pt;
  58. font-family: Monotype Corsiva, Palatino, Georgia, Times New Roman, serif;
  59. font-weight: bold;
  60. text-align: center;
  61. }
  62. #titre p.p4 {
  63. padding-left:30px;
  64. padding-right:30px;
  65. line-height:1.2em;
  66. font-style:italic;
  67. font-size:14pt;
  68. font-family: Monotype Corsiva, Palatino, Georgia, Times New Roman, serif;
  69. font-weight: bold;
  70. text-align: center;
  71.     margin-bottom:0;
  72. }
  73. div#corps_de_texte {
  74. margin-top:0px;
  75. position:absolute;
  76. background:url(feuille.gif) repeat-y;
  77. padding-left:35px;
  78. padding-right:245px;
  79. padding-top:5px;
  80. padding-bottom:30px;
  81. text-align: center;
  82. width:520px;
  83. min-height:500px;
  84. }
  85. div#bas_de_page {
  86. position:relative;
  87. background:url(feuille.gif) repeat-y;
  88. padding-left:35px;
  89. padding-right:245px;
  90. text-align: center;
  91. width:520px;
  92. }
  93. div#menu {
  94. position:absolute;
  95. margin-top:0px;
  96. right:0;
  97. padding-left:5px;
  98. padding-right:5px;
  99. text-align: center;
  100. width:180px;
  101. }
  102. div#menu_haut {
  103. position:relative;
  104. background:url(menu_haut.gif) no-repeat;
  105. width:180px;
  106. height:47px;
  107. }
  108. div#menu_centre {
  109. position:relative;
  110. background:url(menu_centre.gif) repeat-y;
  111. margin-bottom:0px;
  112. padding-top:15px;
  113. padding-bottom:15px;
  114. padding-left:0px;
  115. padding-right:5px;
  116. text-align: center;
  117. width:180px;
  118. line-height:0em;
  119. height:340px;
  120. }
  121. div#menu_bas {
  122. position:relative;
  123. background:url(menu_bas.gif) no-repeat;
  124. margin-top:0px;
  125. line-height:0em;
  126. width:180px;
  127. height:50px;
  128. }
  129. .menu {
  130. font: 8pt Palatino, Georgia, Times New Roman, serif;
  131. color:#554;
  132. text-align:center;
  133. }


 
Toujours à la même adresse : http://modelephp.free.fr/reindex.php
 
J'ai également un décalage au niveau des hyperliens du menu et ils ne sont plus "cliquables" aprés un certain nombre de lignes...
D'ailleurs le design est comme souhaité sous FF3
 
Au cas ou...

Message cité 1 fois
Message édité par alx067 le 27-06-2009 à 08:38:04
n°1899685
phosphorel​oaded
Posté le 27-06-2009 à 12:14:40  profilanswer
 

alx067 a écrit :

le <hr /> n'y est pour rien, j'ai tenté de le virer dans aucun effet (la marge est encore plus grande (toujours sous FF3)...)
Adresse web : http://modelephp.free.fr/


Sur art*.fr c'est bien le <hr /> :o
 

alx067 a écrit :

J'ai également un décalage au niveau des hyperliens du menu et ils ne sont plus "cliquables" aprés un certain nombre de lignes...


Et comme par hasard un bloc positionné en absolu commence pile là où les liens commencent à ne plus être cliquables :)
 
http://hfr-rehost.net/img29.imageshack.us/img29/3734/liensmenuposabsolute.jpg

n°1900108
alx067
Posté le 29-06-2009 à 13:25:10  profilanswer
 

Il reste encore un petit détail.
 
Il reste un décalage dans le titre de la page, l'affichage est différent sous IE8 et sous FF3. J'espérais trouver une solution en cherchant mais sans succès...
 
Et le titre des images ne s'affichent pas sous FF3. ???
 
http://contactartisia.free.fr/artisia3.jpg
 
Je laisse le code :

Code :
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr" lang="fr">
  3. <head>
  4. <?php include("textes_et_mise_en_page/meta.txt" ); ?>
  5. <!-- Inspiré de CSS Garden (http://www.csszengarden.com/tr/francais) -->
  6. <title><?php include("coordonnees/nom_de_l_entreprise.txt" ); ?> - Accueil</title>
  7. <link href="style/style.css" rel="stylesheet" type="text/css" media="all" />
  8. <link rel="Shortcut Icon" type="image/x-icon" href="artisia.ico" />
  9. </head>
  10. <body>
  11. <div id="contenant">
  12.   <div id="balise_gauche">
  13.     <img src="style/logo_inscrustation.gif" width="60" height="140" />
  14.     <img src="style/logo_reduit.jpg" alt="<?php include("coordonnees/nom_de_l_entreprise.txt" ); ?>" width="150" height="140" />
  15.   </div>
  16.  
  17.   <div id="balise_droite">
  18.     <?php include("textes_et_mise_en_page/balise_droite.txt" ); ?>
  19.   </div>
  20.  
  21.   <div id="haut_de_page"></div>
  22.  
  23.   <div id="menu">
  24.  
  25.     <div id="menu_haut"></div>
  26.    
  27.     <div id="menu_centre" class="menu">
  28.     <p><?php include("textes_et_mise_en_page/menu.txt" ); ?></p>
  29.     </div>
  30.    
  31.     <div id="menu_bas"></div>
  32.    
  33.   </div>
  34.  
  35.   <div id="titre">
  36.     <p class="p3"><?php include("coordonnees/nom_de_l_entreprise.txt" ); ?></p>
  37.     <p class="p4"><?php include("coordonnees/devise_de_l_entreprise.txt" ); ?></p>
  38.   </div>
  39.  
  40.   <div id="corps_de_texte">
  41.     <h3>Bienvenue !</h3>
  42.     <p>&nbsp;</p>
  43. </div>
  44.  
  45.   <div id="bas_de_page">
  46.     <p><?php include("textes_et_mise_en_page/bas_de_page.txt" ); ?></p>
  47.   </div>
  48.  
  49.   <div id="bas_de_feuille"></div>
  50.  
  51. </div>
  52. </body>
  53. </html>


 

Code :
  1. /* CSS Document */
  2. body {
  3. font: 10.5pt Palatino, Georgia, Times New Roman, serif;
  4. color:#554;
  5. background-image: url(fond.jpg);
  6. background-repeat: no-repeat;
  7. background-color: #fd5121;
  8. }
  9. a:link, a:visited, a:active {
  10. font-style:italic;
  11. color:black;
  12. font-weight:300;
  13. text-decoration:none;
  14. }
  15. a:hover {
  16. font-style:italic;
  17. color:#B8860B;
  18. text-decoration:underline;
  19. }
  20. /* Body Element */
  21. #contenant {
  22. position:absolute;
  23. left:50%;
  24. width:800px;
  25. margin-left:-400px;
  26. top:0px;
  27. }
  28. div#balise_gauche {
  29. background:url(etiquette.gif) no-repeat;
  30. width:278px;
  31. height:185px;
  32. margin:0px;
  33. }
  34. #balise_droite {
  35. position:absolute;
  36. width:235px;
  37. height:199px;
  38. right:0px;
  39. top:0px;
  40. }
  41. div#haut_de_page {
  42. position:relative;
  43. background:url(page_haut.gif) no-repeat;
  44. height:19px;
  45. width:600px;
  46. margin:0px;
  47. }
  48. div#titre {
  49. background:url(page_titre.gif) repeat-y;
  50. width:534px;
  51. height:88px;
  52. margin:0px;
  53. padding-left:28px;
  54. padding-right:20px;
  55. padding-top:10px;
  56. padding-bottom:10px;
  57. text-align: center;
  58. }
  59. #titre p.p3 {
  60. padding-left:30px;
  61. padding-right:30px;
  62. padding-top:5px;
  63. padding-bottom:5px;
  64.     line-height:10px;
  65. font-style:italic;
  66. font-size:18pt;
  67. font-family: Monotype Corsiva, Palatino, Georgia, Times New Roman, serif;
  68. font-weight: bold;
  69. text-align: center;
  70. }
  71. #titre p.p4 {
  72. padding-left:30px;
  73. padding-right:30px;
  74. padding-top:5px;
  75. padding-bottom:5px;
  76.     line-height:10px;
  77. font-style:italic;
  78. font-size:14pt;
  79. font-family: Monotype Corsiva, Palatino, Georgia, Times New Roman, serif;
  80. font-weight: bold;
  81. text-align: center;
  82. }
  83. div#corps_de_texte {
  84. position:relative;
  85. margin:0px;
  86. background:url(page_centre.gif) repeat-y;
  87. padding-left:28px;
  88. padding-right:20px;
  89. padding-top:30px;
  90. padding-bottom:10px;
  91. text-align: center;
  92. width:534px;
  93. min-height:752px;
  94. }
  95. div#bas_de_page {
  96. position:relative;
  97. margin:0px;
  98. background:url(page_titre.gif) repeat-y;
  99. padding-left:28px;
  100. padding-right:20px;
  101. padding-top:5px;
  102. padding-bottom:5px;
  103. text-align: center;
  104. width:534px;
  105. height:62px;
  106. font-size:10px;
  107. }
  108. div#bas_de_feuille {
  109. position:relative;
  110. margin:0px;
  111. background:url(page_bas.gif) no-repeat;
  112. text-align: center;
  113. width:600px;
  114. height:23px;
  115. }
  116. div#menu {
  117. position:absolute;
  118. margin-top:50px;
  119. right:0;
  120. padding-left:5px;
  121. padding-right:5px;
  122. text-align: center;
  123. width:180px;
  124. }
  125. div#menu_haut {
  126. position:relative;
  127. background:url(menu_haut.gif) no-repeat;
  128. width:180px;
  129. height:47px;
  130. }
  131. div#menu_centre {
  132. position:relative;
  133. background:url(menu_centre.gif) repeat-y;
  134. padding-top:5px;
  135. padding-bottom:5px;
  136. padding-left:0px;
  137. padding-right:5px;
  138. text-align: center;
  139. width:180px;
  140. line-height:1em;
  141. height:260px;
  142. }
  143. div#menu_bas {
  144. position:relative;
  145. background:url(menu_bas.gif) no-repeat;
  146. margin-top:0px;
  147. width:180px;
  148. height:50px;
  149. }
  150. .menu {
  151. font: 8pt Palatino, Georgia, Times New Roman, serif;
  152. color:#554;
  153. text-align:center;
  154. }


 
Toujours la même page http://modelephp.free.fr/
 
J'ai regardé sur ce site http://browsershots.org/ est la majorité des navigateurs affiche le site.
:sarcastic:


Message édité par alx067 le 29-06-2009 à 13:51:05
n°1900325
David Bori​ng
Posté le 29-06-2009 à 18:39:19  profilanswer
 

Firefox a bien raison de ne pas afficher le alt car l'image est présente
Toi, tu veux employer un title
http://www.webmasterworld.com/acce [...] 252877.htm

n°1900374
phosphorel​oaded
Posté le 29-06-2009 à 21:10:40  profilanswer
 

Aller à :
Ajouter une réponse
  FORUM HardWare.fr
  Programmation
  HTML/CSS

  Problème d'alignement CSS dans les balises

 

Sujets relatifs
Problème d'affichage d'image dans un ForumProbleme définition librairie
Problème Doublons Ongletprobléme de numerotation des fichiers lors du download
probleme pour parser des dates [résolu]Problème java.lang.NullPointerException
Problème d'importation PhpMyAdminProbleme menu déroulant
problème avec un update[Resolu]Problème de compilation API MYSQL
Plus de sujets relatifs à : Problème d'alignement CSS dans les balises


Copyright © 1997-2022 Hardware.fr SARL (Signaler un contenu illicite / Données personnelles) / Groupe LDLC / Shop HFR