bonjour à tous,
grâce aux cours donnés sur le site et quelques recherches sur internet j'ai pu construire pour premier site en css.
il y as juste une chose que j'arrivais à faire avec des <table> (oui mais les table c'est pas bien) et que je n'arrive pas à refaire, c'est d'avoir mon menu aussi 'haut' que le corps de ma page.
en gros j'ai ce code :
le html :
et le css :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37 <body> <!-- ######### --> <div id="fond"> <!-- ######### --> <div id="top"> <object width="800" height="180" align="middle"> <embed src="head.swf" quality="high" bgcolor="#ffffff" width="800" height="160" name="head" align="middle" /> </object> </div> <!-- ######### --> <div id="menu"> <div id="menuH"> </div> <div class="lvl1"><a href="index.php"> Accueil</a></div> <div class="lvl1"><a href="index.php?page=1">1</a></div> <div class="lvl1"><a href="index.php?page=2">3</a></div> <div class="lvl1"><a href="index.php?page=test">test</a></div> <div id="menuB"> </div> </div> <!-- ######### --> <div id="corp"> <div id="corpH"> </div> <div id="corpC"> <?php if($_GET['page']) include($_GET['page'].".html"); else include("index.php"); ?> </div> <div id="corpB"> </div> </div> <!-- ######### --> <div id="fin"> fin </div> </div> </body> </html>
mais les tailles de mon corps et de mon menu ne sont jamais égales ce qui m'embête un peut ...
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114 html,body { background-color : white; } #fond { background-color:transparent; width:800px; } /* ===================================================== */ /* ====================== HEAD ========================= */ /* ===================================================== */ #top { background-color:transparent; margin:0; padding:0; text-align:justify; width:800px; height:auto; } /* ===================================================== */ /* ====================== MENU ========================= */ /* ===================================================== */ #menu { display:block; width:215px; float:left; background:url("img/menuC.png"); background-repeat:repeat-y; } #menuH { width:215px; height:41px; padding:0; background:url("img/menuH.png"); background-color:#FFFFFF; background-repeat:no-repeat; } #menuB { width:215px; height:41px; padding:0; background:url("img/menuB.png"); background-color:#FFFFFF; background-repeat:no-repeat; } .lvl1 a, .lvl1 a:active, .lvl1 a:visited { font: bold 16px arial, serif; text-decoration: none; padding:6px 10px; margin-left:7px; background:url("img/MenuBtmOff.gif") no-repeat left top; display:block; color:#3366FF; } .lvl1 a:hover { background:url("img/MenuBtmOn.gif") no-repeat; color:#99CC66; } /* ===================================================== */ /* ====================== CORP ========================= */ /* ===================================================== */ #corp { background-color:transparent; text-align:justify; width:585px; float:right; } #corpH { width:585px; height:38px; padding:0; background:url("img/corpH.png"); background-color:#FFFFFF; background-repeat:no-repeat; } #corpB { width:585px; height:38px; padding:0; background:url("img/corpB.png"); background-color:#FFFFFF; background-repeat:no-repeat; } #ccorp { width:585px; padding:0; background:url("img/corpC.png"); background-color:#FFFFFF; background-repeat:repeat-y; } /* ===================================================== */ /* ====================== FIN ========================= */ /* ===================================================== */ #fin { background-color:transparent; width:800px; /*height:300px;*/ text-align:center; }
voila tout.
Si quelqu'un as un solution à mon problème !
en attendant je retourne sur mon ami google (des fois qu'il trouve qu'autre info !!)
Partager