[Resolu] [CSS+XHTML] problème de décalage - Programmation
Ceci répond-il à votre question ? Oui | Non
 

Ajouter une réponse



 Mot :   Pseudo :  
 
Bas de page
Auteur
 Sujet : [Resolu] [CSS+XHTML] problème de décalage
 
Profil : IDNaute
Plus d'informations

Bonjour tout le monde; j'ais une petit problème de décallage,
dans mon iframe, les images semblent être poussées ver la droite:

Un apercu
cliquez ici

CSS:

Code :
  1. body
  2. {
  3. overflow:hidden;
  4. overflow-x: hidden;
  5. overflow-y: auto;
  6. overflow : -moz-scrollbars-vertical;
  7. background-color:#313131;
  8. font-size:11px;
  9. color:#313131;
  10. font-family:Arial, Helvetica, "Nimbus Sans L", sans-serif;
  11. font-weight:bold;
  12. }
  13. a img{border:none;text-decoration:none;}
  14. a{text-decoration:none;color:#167587;}
  15. a:hover{color:silver;}
  16. #iframe
  17. {
  18. width:700px;
  19. background-color:#313131;
  20. overflow:hidden;
  21. border:1px solid white;
  22. }
  23. .bouton2:hover{height:auto;}
  24. .sousbouton a{text-decoration:none; color:#167587;}
  25. .sousbouton a:hover{color:silver;}
  26. .sousbouton
  27. {
  28. background-color:#313131;
  29. font-size:11px;
  30. }
  31. .gallerie
  32. {
  33. border:1px solid red;
  34. position:relative;
  35. top:0px;
  36. left:0px;
  37. width:700px;
  38. margin:auto;
  39. background-color:#313131;
  40. }



HTML de la page principal:

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" >
  3.   <head>
  4.       <title>aREA-51</title>
  5.       <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  6.       <link rel="shortcut icon" type="image/x-icon" href="area.ico" />
  7.       <script>
  8. function actu_iframe(){
  9. if(navigator.appName=="Microsoft Internet Explorer" ){
  10. if(document.all) document.all.id_iframe.style.height = document.frames("iframe" ).document.body.scrollHeight;
  11. else document.getElementById("iframe" ).style.height = document.getElementById("iframe" ).contentDocument.body.scrollHeight;
  12. }
  13. else{
  14. document.getElementById("iframe" ).style.height = document.getElementById("iframe" ).contentDocument.body.offsetHeight+"px";
  15. }
  16. }
  17. </script>     
  18. <!--[if lt IE7]>
  19.                 <script>
  20.                 function actu_iframe()
  21. {
  22. if(document.all) document.all.iframe.style.height = document.frames("iframe" ).document.body.scrollHeight;
  23. else document.getElementById("iframe" ).style.height = document.getElementById("iframe" ).contentDocument.body.scrollHeight;
  24. }
  25. </script>
  26.         <![endif]-->
  27. <link rel="stylesheet" media="screen" type="text/css" title="clearblack" href="hithesky.css"/>
  28.   </head>
  29.  
  30. <body>
  31. <div class="frame">
  32.         <iframe onLoad="actu_iframe();" name="I1"id="iframe" src="index/+.html" scrolling="no" frameborder=no>Votre navigateur ne supporte pas les
  33.         frames.</iframe>
  34.         </div>
  35. <a id="menulien" href="info/info.html" target="I1">
  36.         <div class="bouton2">
  37.             aREA-51
  38.         </div>
  39.         </a>



HTML d'une page contenant un image (contenu décalé dans l'iframe):

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" >
  3.   <head>
  4.       <title>BLOC-418²</title>
  5.       <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  6.       <link rel="stylesheet" media="screen" type="text/css" title="clearblack" href="../../hithesky.css"/>
  7.       <link rel="shortcut icon" type="image/x-icon" href="area.ico" />
  8.   </head>
  9.   <body>
  10.         <div class="gallerie">
  11.         <img src="+2.jpg"/>
  12.         </div>
  13.     </body>
  14. </html>



Je pense que ce problème de décalage a un rapport avec l'image et sont div conteneur.... help pleas. Merci d'avance! [cligne]


Message édité par stickmania k le 20-06-2007 à 10:51:59
Liens

Profil : IDNaute
Plus d'informations

Je ne vois pas le problème ! :D Nonnon, j'ai rien bu !


Message édité par sangoku538 le 20-06-2007 à 09:46:00

---------------
La théorie c'est quand on sait tout mais que rien ne fonctionne, la pratique c'est quand tout fonctionne mais personne ne sait pourquoi ; nous avons réunis ici pratique et théorie --> rien ne fonctionne et personne ne sais pourquoi
Albert Einstein
Profil : IDNaute
Plus d'informations

Lol, je post une image pour que se soit plus claire:
http://stickart.ifrance.com/area51/problème.jpg

- La marge rouge représente la div gallerie qui contient l'image.
C'est la page qui est charger dans mon iframe.
- La marge blanche représente l'iframe.

Il y a bel et bien un décalage, sous IE comme sous FF.
help pleas :??:

Profil : IDNaute
Plus d'informations

Ah ok merci, je vais essayer d'y réfléchir ^^


---------------
La théorie c'est quand on sait tout mais que rien ne fonctionne, la pratique c'est quand tout fonctionne mais personne ne sait pourquoi ; nous avons réunis ici pratique et théorie --> rien ne fonctionne et personne ne sais pourquoi
Albert Einstein
Profil : IDNaute
Plus d'informations

Résolu: margin:0px et padding:0px a mon body, les marges ont disparu. Bonne journée all!

Profil : IDNaute
Plus d'informations

Ok, dsl de ne pas avoir trouvé avant toi ... ^^


---------------
La théorie c'est quand on sait tout mais que rien ne fonctionne, la pratique c'est quand tout fonctionne mais personne ne sait pourquoi ; nous avons réunis ici pratique et théorie --> rien ne fonctionne et personne ne sais pourquoi
Albert Einstein

Aller à :
Ajouter une réponse
  FORUM Infos-du-Net » Programmation » [Resolu] [CSS+XHTML] problème de décalage
 

Liens