Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [HTML][CSS]menu dla każdej podstrony
imysz
post
Post #1





Grupa: Zarejestrowani
Postów: 54
Pomógł: 0
Dołączył: 16.08.2009

Ostrzeżenie: (0%)
-----


Witam. chodzi mi o zrobienie czegoś takiego jak na zdjęciu zarysowałem. W zależności od tego na której podstronie się znajdujemy wtedy bloczek z menu łączy się z dużym blokiem tekstu i podświetlony napis na kolor czerwony. jak widać na załączonym obrazku. I żeby zrobić tak do wszystkich. Jest to możliwe ?

http://www.fotosik.pl/pokaz_obrazek/66f7ef25f8e144c7.html


xhtml
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  2. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="pl" lang="pl">
  3.  
  4. <title>projekt_02</title>
  5. <meta http-equiv="content-type" content="text/html; charset=UTF-8" />
  6. <meta http-equiv="content-language" content="pl" />
  7. <link rel="stylesheet" href="style.css" type="text/css" />
  8. </head>
  9.  
  10. <div id="page">
  11.  
  12. <div id="header">
  13.  
  14. <form action="" method="post">
  15. Login:
  16. <input type="text" name="login" class="form_log" />
  17. Password:
  18. <input type="password" name="pass" class="form_log" />
  19. <input type="submit" value="Zaloguj" />
  20. </form>
  21.  
  22. </div>
  23.  
  24.  
  25.  
  26.  
  27. <div id="wrapper">
  28. <p>text wrappertext wrapperteext wrapperteext wrapperteext wrappertext wrappertext wrappertext wrappertext wrappertext wrappertext wrappertext wrappertext wrappertext wrapper</p>
  29.  
  30. <div id="menu">
  31.  
  32. <ul>
  33. <li class="first"><a class="first" href="">Home</a></li>
  34. <li><a class="Other" href="">Page 1</a></li>
  35. <li><a class="Other" href="">Page 2</a></li>
  36. <li><a class="Other" href="">Page 3</a></li>
  37. <li ><a class="Other" href="">Page 4</a></li>
  38. </ul>
  39.  
  40. </div>
  41. </div>
  42.  
  43.  
  44. </div>
  45. </body>



css
  1. body{
  2. background-color: #E8E8E8
  3. }
  4.  
  5. #header{
  6. background-color:white;
  7. width:785px;
  8. margin:0 auto;
  9. margin-top:10px;
  10. margin-bottom:20px;
  11. padding:8px;
  12. border: 1px solid #A9A9A9;
  13.  
  14. }
  15.  
  16.  
  17. #wrapper{
  18. background-color:white;
  19. margin: 0 auto;
  20. width:780px;
  21. padding:10px;
  22. border: 1px solid #A9A9A9;
  23. font-size:1.5em;
  24. font-family:Curier New;
  25. text-align:center;
  26.  
  27. }
  28.  
  29. #menu{
  30. position:relative;
  31. left:-179px;
  32. top:14px;
  33. }
  34.  
  35. #menu ul{
  36. width:130px;
  37. font-size:15px;
  38. position:absolute;
  39. margin-top:15px;
  40.  
  41. }
  42.  
  43. #menu li {
  44. display: block;
  45. list-style: none;
  46.  
  47. }
  48.  
  49. #menu a {
  50. display: block;
  51. text-decoration:none;
  52. padding:10px 10px 10px 10px;
  53. border:1px solid #a9a9a9;
  54. text-align:left;
  55. border-right: 1px solid white;
  56. font-weight:bold;
  57. font-size:12px;
  58. font-family:"Lucida Grande", Arial, Helvetica, Verdana, sans-serif;
  59.  
  60.  
  61. }
  62.  
  63. #menu ul a:hover{
  64. color:#D51007;
  65. background:white;
  66. font-weight:bolder;
  67. }
  68. .first{
  69. margin-right:20px;
  70. width:110px;
  71. background-color:white;
  72. color:#D51007;
  73. border-bottom:0px solid white;
  74.  
  75. }
  76. .Other{
  77. background-image: url('media/menubg.png') ;
  78. color:gray;
  79. }
  80. .form_log{
  81. background-image:url('media/formbg.gif');
  82. }
Go to the top of the page
+Quote Post

Posty w temacie


Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 21.08.2025 - 03:08