28220 sujets

CSS et mise en forme, CSS3

Salut a tous j'ai un petit souci pour afficher une image en arriere plan d'un div, je ne sais pas pourquoi elle ne passe pas et on ne la voit pas .....


body {font: 14px Verdana, Arial, sans-serif;
background-color: #fff}

ul {list-style-type: none;
margin: 0;
padding: 0;}

h1 {
font: 18px Verdana, Arial, sans-serif;
text-decoration:underline 2 px dotted;
}
.menu a{
display:block;
height: 20px;
width: 300px;
text-decoration: none;
color:#000;
text-indent:20px;
background-image:url(button.png);
background-position: left center;
background-repeat: no-repeat;
}
	 
.menu a:hover{
background-image:url(button_on.png);
background-position: left center;
background-repeat: no-repeat;
color:purple;
}

.menu {
height:400px;
top:25px;
position:absolute;
float:left !important;
}
/* ---------------- [HEADER]  ---------------------------- */

#body_page {
float:left;
top:100;
left:100;
height:450px;
width:600px;
position:absolute;
font:10pt Verdana, Helvetica, Arial, sans-serif;
background:url("fond_body.png") no-repeat;
background-position: 10% 300px;
z-index:2;
}

#header {
float:left;
top:0;
left:25;

position:absolute;
z-index:200;
}

#text {
align:left
height:400px;
left:250px;
top:25px;	
position:absolute;
float:left;
border:1px solid black;
padding-right:15px;
padding-left:15px;
padding-top:5px;
padding-bottom:5px;

}


header_one {


background:url("pictures/banner.gif") no-repeat;
z-index:500;
background-position: 10% 300px;
}


/* ----------------  [MENU]  --------------------------- */



/* -------------  [LINKS]  ----------------------------*/




et le codfe de la page :



<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link type="text/css" rel="stylesheet" href="feuille_de_style.css" />

<style type="text/css">
<!--
@import url("feuille_de_style.css");
-->
</style>
</head>

<body>
<div id="body_page">
<div id="header_one">< !-- <img src="/gp_game/pictures/banner.gif"> --></div>
  <div id="header"></div>
<div id="menu" width="100">
    <ul class="menu">
      <li><a href="#">Menu 1</a></li>
      <li><a href="#">Menu 2</a></li>
      <li><a href="#">Menu 3</a></li>
      <li><a href="#">Menu 4</a></li>
    </ul>
</div>
  <div id="text"> 
    <h1>Big Title</h1>
    <br />
    <p>Although the idea of the Grand Prix has been around since the turn of the 
      Twentieth Century, F1 as we know it has only existed since the 1950s. There 
      had been a number of large European race meetings prior to this date, but 
      the idea of a drivers' championship had not been effectively put into place. 
    </p>
    <br />
    <p>The first F1 race was held at Silverstone in May 1950 and was won by the 
      legendary driver Nino Farina in an Alfa Romeo. He went on to win the first 
      two world championships, but was soon eclipsed by the first real F1 superstar 
      and Farina's one-time team-mate Juan-Manuel Fangio. The Argentinean went 
      on to win five world championships in fantastic style, and was only denied 
      more trophies by frequent injuries. 1952 saw him suffer his first major 
      accident, at Monza, when he broke his neck and had to miss the rest of the 
      season. He had promised to race at Monza following a race in Belfast but 
      due to missed connections he found himself driving all night from Paris 
      only to arrive at the circuit one half hour prior to the race. Having to 
      start from the back of the grid he made an unusual mistake and the Maserati 
      he was driving went into a slide. Being extremely tired his reactions were 
      not what they would normally have been and he could not regain control of 
      the car before it hit a bank and somersaulted into the air. Fangio was thrown 
      out and would spend the next few hours near death under doctors' supervision. 
      He retired after the French Grand Prix of 1958.</p>
    <br />
    <p>In 1961, the allowed engine capacity of the cars was increased to 1500cc, 
      and was further increased to 3000cc in 1966. F1 was dominated by British 
      drivers throughout the 1960s, with the notable exception of Jack Brabham 
      (whose grandparents had emigrated from Britain to Australia) who won three 
      world championships as a driver and successfully founded his own team, which 
      was to win the constructors' championship in 1966 and 1967. </p>
    <br />
    <p>The 1970s saw the development of wings on the cars, and was a decade ruled 
      by now famous racing names - Emerson Fittipaldi, Nicky Lauda and Jackie 
      Stewart. It was also the decade in which legendary playboy James Hunt won 
      the world championship - he capitalised after Lauda had a horrific crash 
      at Germany's Nurburgring, from which he recovered in just 40 days. </p>
    <br />
    <p>The 1980s was the era of Alain Prost and Nelson Piquet, not to mention 
      the remarkable drivers' championship win for Lauda in 1984, nine years after 
      his last title. The world was also introduced to the awesome talents of 
      the young Brazilian Ayrton Senna. </p>
    <br />
    <p>Arguably the most significant event in 1990s F1 was the untimely death 
      of Senna at Imola in 1994. He had previously driven for Mclaren and was 
      just four races into his Career at leading team Williams when tragedy struck 
      and he flew off the track at high speed and crashed into a barrier. The 
      recent focus on slowing the cars down has been spurred on largely by this 
      event. Senna's death robbed the sport of a champion, and arguably the one 
      man who could have offered Michael Schumacher real competition. </p>
    <br />
  </div>
</div> 
</body>
</html>


Voila si vous avez des solutions a me proposer je suis tout ouï

Guillaume
Bonjour

Quel est le div concerné ?

Le code qui marche :

background: #fff url(images/mon_image.gif) no-repeat top left;


Tes erreurs possible :

Le png
Les guillemets dans l'url
Problèmes de chemin d'url...
Administrateur
Si je ne m'abuse, il s'agit d'une question de mise en forme.
Donc je déplace dans le salon "CSS et mise en forme" Smiley cligne