bestimmte Seite soll beim Start sofort geladen werden

joel-87

Lt. Commander
Registriert
Sep. 2006
Beiträge
1.521
Hallo,
mein Problem ist Folgendes:
Sobald die index.php geladen ist, soll sofort der Inhalt von home.php in dem Main-Bereich erscheinen. Wenn ich nun auf HOME klicke soll der Inhalt logischerweise weiterhin bestehen. Wie kann man das realisieren?

http://www.slide-a-lama.net

PHP:
<html>
<head>
<title></title>
<meta name="author" content="Administrator">
</head>
<!--[if lte IE 6]>
<script type="text/javascript">
function correctPNG() // correctly handle PNG transparency in Win IE 5.5 or higher.
   {
   for(var i=0; i<document.images.length; i++)
      {
      var img = document.images[i]
      var imgName = img.src.toUpperCase()
      if (imgName.substring(imgName.length-3, imgName.length) == "PNG")
         {
         var imgID = (img.id) ? "id='" + img.id + "' " : ""
         var imgClass = (img.className) ? "class='" + img.className + "' " : ""
         var imgTitle = (img.title) ? "title='" + img.title + "' " : "title='" + img.alt + "' "
         var imgStyle = "display:inline-block;" + img.style.cssText
         if (img.align == "left") imgStyle = "float:left;" + imgStyle
         if (img.align == "right") imgStyle = "float:right;" + imgStyle
         if (img.parentElement.href) imgStyle = "cursor:hand;" + imgStyle
         var strNewHTML = "<span " + imgID + imgClass + imgTitle
         + " style=\"" + "width:" + img.width + "px; height:" + img.height + "px;" + imgStyle + ";"
         + "filter:progid:DXImageTransform.Microsoft.AlphaImageLoader"
         + "(src=\'" + img.src + "\', sizingMethod='scale');\"></span>"
         img.outerHTML = strNewHTML
         i = i-1
         }
      }
   }
window.attachEvent("onload", correctPNG);
</script>
<![endif]-->

<body text="#000000" bgcolor="#1d1b1b" link="#FF0000" alink="#FF0000" vlink="#FF0000">

<table border="0" cellspacing="0" width="970" cellpadding="0" align="center">
<tr>
<td colspan="3" width="970" height="120"> <? include ("header.php") ;?></td>
</tr>
<td colspan="3" width="970" height="30"> <? include ("navi.php") ;?></td>
</table>

<table style="border-width:medium; border:5; border-color:#000000 ; border-style:double; padding:8px; border-top-style:none" width="970" align="center">
<tr>
<td style="border:1px solid black" width="160">Werbung</td>
<td style="border:1px solid black; background-image:url(pics/fgdfblume.gif)" width="640">
<?php
switch ($_GET['site']) {
          case "home":
                  include("home.php");
                  break;
          case "sal":
                  include("sal.php");
                  break;
          case "about":
                  include("about.php");
                  break;
          case "forum":
                  include("forum.php");
                  break;
          case "guestbook":
                  include("gaestebuch.php");
                  break;
          case "links":
                  include("links.php");
                  break;
          case "impressum":
                  include("impressum.php");
                  break;
};
?>
</td>
<td style="border:1px solid black" width="170"> <? include ("shoutbox.php") ;?></td>
</tr>
<tr>
<td colspan="3" width="970">
<? include ("footer.php") ;?> Footer
</td>
</tr>
</table>
</body>
</html>

Was muss ich im Code ergänzen, um dieses Problem zu lösen???
 
Zuletzt bearbeitet:
PHP:
<?php
switch ($_GET['site'])
{
  case 'home':
    include 'home.php';
    break;
  case 'sal':
    include 'sal.php';
    break;
  case 'about':
    include 'about.php';
    break;
  case 'forum':
    include 'forum.php';
    break;
  case 'guestbook':
    include 'gaestebuch.php';
    break;
  case 'links':
    include 'links.php';
    break;
  case 'impressum':
    include 'impressum.php';
    break;
  default:
    include 'home.php';
    break;
}
?>
 
Super, genau das hab ich gesucht. Leider nix mit googeln gefunden. War ja wirklich ganz einfach hehe, vielen vielen Dank.:D
 
Zurück
Oben