Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> Otwieranie linku w innym div'ie, błędy
sushim
post
Post #1





Grupa: Zarejestrowani
Postów: 2
Pomógł: 0
Dołączył: 2.11.2012

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


Witam,
Zacząłem na szybko tworzyć stronkę w celu poćwiczenia php ale nie wychodzi mi to za bardzo bo jakoś ciągnie mnie do html'a
Z htmlem miałem trochę doczynienia ale jakiś super to nie jestem chciałem stworzyć coś w php i zacząłem od takiej prostej strony, problem w tym że chce aby linki które są w menu na górze otwierały się w div'ie "srodek" i nie bardzo wiem jak zrobić żeby miało to ręce i nogi?? Wstawiam kod który działa ale wyrzuca na początku błędy, może ma ktoś ochotę zerknąć i powiedzieć mi do jest nie tak?? (IMG:style_emoticons/default/wink.gif)
  1. <!DOCTYPE html>
  2.  
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  5. <title>aaaa</title>
  6. <link rel="stylesheet" href="css/style.css" media="screen" type="text/css" />
  7. </head>
  8. <body>
  9. <div id ="a1">
  10.  
  11. <div class="logo">
  12.  
  13. </div>
  14. <div class="przyciski1">
  15. <ul class="menu_poziome" style="font-size: 12px; font-family: Calibri">
  16. <li><a href="index.php?id=start">Strona Główna</a></li>
  17. <li><a href="index.php?id=www">WWW</a></li>
  18. <li><a href="index.php?id=ztp">ZTP</a></li>
  19. <li><a href="index.php?id=io">IO</a></li>
  20. <li><a href="index.php?id=npto">NPTO</a></li>
  21. <li><a href="index.php?id=wpf">BAUwWPF</a></li>
  22. <li><a href="index.php?id=amzl">AMZL</a></li>
  23. </ul>
  24.  
  25. </div>
  26. <div class="przyciski2">
  27.  
  28. </div>
  29. <div class="menu_lewe" style="height:912px; width:122px; overflow: hidden">
  30.  
  31. </div>
  32. <div class="srodek" style =" height: 912px; width: 656px; overflow: hidden">
  33.  
  34. <?php
  35.  
  36. if(empty($_GET['id']) or $_GET['id']=="start"){
  37. include("start.php");
  38. }
  39.  
  40. if($_GET['id']=="www"){
  41. include("www.html");
  42. }
  43.  
  44. if($_GET['id']=="ztp"){
  45. include("ztp.php");
  46. }
  47.  
  48. if($_GET['id']=="io"){
  49. include("io.php");
  50. }
  51.  
  52. if($_GET['id']=="npto"){
  53. include("npto.php");
  54. }
  55. if($_GET['id']=="wpf"){
  56. include("wpf.php");
  57. }
  58. if($_GET['id']=="amzl"){
  59. include("amzl.php");
  60. }
  61.  
  62. ?>
  63. </div>
  64. <div class="menu_prawe" style="height:912px; width:122px; overflow: hidden">
  65.  
  66. </div>
  67. <div class="stopka" style="height: 102px; width: 900px; overflow: hidden">
  68.  
  69. </div>
  70. </div>
  71. </body>
  72. </html>


  1. /*
  2.   Document : style
  3.   Created on : 2012-11-01, 00:44:44
  4.   Author : sushi
  5.   Description:
  6.   Purpose of the stylesheet follows.
  7. */
  8.  
  9. /*
  10.   TODO customize this sample style
  11.   Syntax recommendation http://www.w3.org/TR/REC-CSS2/
  12. */
  13. body{
  14. background-color: #0d090f;
  15. }
  16.  
  17. #a1{
  18. position:relative;
  19. margin:auto;
  20. width:900px;
  21. height: auto;
  22. min-height: 750px;
  23. }
  24. .logo{
  25. position: relative;
  26. min-height: 150px;
  27. width: 900px;
  28. background: url(../images/logo.png);
  29. }
  30. .przyciski1{
  31. position: relative;
  32. background: url(../images/przyciski1.png);
  33. height: 19px;
  34. width: 900px;
  35. }
  36. .przyciski2{
  37. position: relative;
  38. background: url(../images/przyciski2.png);
  39. height: 17px;
  40. width: 900px;
  41. }
  42. .menu_lewe{
  43. position: absolute;
  44. background: url(../images/menu_lewe.png);
  45. }
  46. .srodek{
  47. position: absolute;
  48. left: 122px;
  49. }
  50. .menu_prawe{
  51. position: relative;
  52. float: right;
  53. background: url(../images/menu_prawe.png);
  54. }
  55. .stopka{
  56. position: relative;
  57. background: url(../images/stopka.png);
  58. }
  59.  
  60. /*menu */
  61. ul, ul li {
  62. display: block;
  63. list-style: none;
  64. margin: 0;
  65. padding: 0px;
  66. }
  67.  
  68. ul {
  69. float: left;
  70. padding: 2px 0 0px 122px;
  71. border: 0px solid #000;
  72. }
  73.  
  74. ul li {
  75. float: left;
  76. }
  77.  
  78. ul a:link, ul a:visited {
  79. text-decoration: none;
  80. display: block;
  81. font-weight: bold;
  82. color: #ff9f03;
  83. padding: 0px 20px;
  84. border-right: 1px solid #fff;
  85. border-right: 1px solid #fff;
  86. }
  87.  
  88. ul a:hover {
  89. background-color: #a4a4a4;
  90. }


Ten post edytował sushim 2.11.2012, 16:17:25
Go to the top of the page
+Quote Post

Posty w temacie


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

 



RSS Aktualny czas: 24.12.2025 - 08:22