Seite 3 von 3 Erste 123
  1. #21
    Avatar von DMW007
    Registriert seit
    15.11.2011
    Beiträge
    6.080
    Thanked 9.118 Times in 2.995 Posts
    Blog Entries
    5

    Standard AW: Layout - Gleicher Spaltenabstand in Tabelle

    iFrame?
    Poste mal den gesamten HTML-Source inklusive CSS-Definitionen. Am besten den fertigen Quelltext einer generierten Seite statt dem originalen PHP-Source.


  2. #22
    Avatar von Saad
    Registriert seit
    18.11.2011
    Beiträge
    786
    Thanked 621 Times in 219 Posts

    Standard AW: Layout - Gleicher Spaltenabstand in Tabelle

    [HIDE=30]
    Die index.html:
    Spoiler:
    HTML-Code:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Testt</title>
    <link rel="stylesheet" href="stylesheet.css" type="text/css">
    </head>
    
    <body>
    
    <div id="wrapper">
    	<div id="header"> SOFTWARE </div>
        <div id="menue"> <?php include "menue.php";?> </div>
        <div id="content"> <iframe src="" scrolling="auto" frameborder="0" width="850" height="310" name="iFrame"></iframe> </div>
        
    </div>
    </body>
    </html>


    Das Stylesheet:
    Spoiler:
    body{

    background-color:#666;

    }

    #wrapper{
    margin:auto;
    width:850px;
    height:500px;
    border: 1px solid black;
    margin-top:25px;
    position:relative;
    font-family: Arial, Helvetica, sans-serif;
    color:#000;
    background-color:#999;
    }

    #header{
    width: 600px;
    height: 20px;
    //border: 1px solid black;
    margin-top: 25px;
    left: 150px;
    position: relative;
    text-align:center;
    padding-top: px;
    font-size:22px;
    text-decoration: underline;

    }
    #menue{
    width: 850px;
    height: 50px;
    border: 1px solid black;
    margin-top:25px;
    position:relative;
    left: -1px;
    background-color:#CCC;
    }
    #content{
    width: 850px;
    height: 310px;
    border: 1px solid black;
    margin-top: 25px;
    left: -1px;
    position: relative;
    background-color:#CCC;

    }

    a:link{
    color:#000;
    text-decoration:none;
    }

    ul{
    margin-top:12px;
    font-family: Arial, Helvetica, sans-serif;
    font-size:20px;
    list-style-type:none;


    }

    li{
    display: inline;
    text-agin:center;
    padding:9px;
    }

    a:hover{
    color:#00;

    }

    a:visited{
    color:#000;
    }


    Die menue.php:
    Spoiler:
    PHP-Code:
    <?php $menus = array("Angebot""Auftrag""Rechnung""Artikel verwalten""Lieferantenstammdaten verwalten");  ?>

    <ul>
      <?php
        
    foreach ($menus as $menu) {
          echo 
    '<li><a target="iFrame" href="'.$menu.'.php">'.$menu.'</li>';
        }
      
    ?>
    </ul>


    Spoiler:

    PHP-Code:

    <style type="text/css">
    .customers {
        width:100%;
    }
    .customers tr td, .customers tr th {
        width:9%;
    }
    </style>

    <?php
    //Verbindung zur Datenbank aufbauen
    $con mysql_connect("localhost","root","");
    mysql_select_db("test");

    echo 
    "<a id='hinzufuegen' href='KAnlegen.php'>Kunden anlegen</a>";
    $result mysql_query("SELECT * FROM kunde"$con);
    echo 
    '<table class="customers" border="0">';
    echo 
    "<tr>";
     echo 
    "<th>ID</th>";
     echo 
    "<th>Vorname</th>";
     echo 
    "<th>Nachname</th>";
     echo 
    "<th>PLZ</th>";
     echo 
    "<th>Ort</th>";
     echo 
    "<th>Strasse</th>";
     echo 
    "<th>Hausnr</th>";
     echo 
    "<th>Telnr</th>";
     echo 
    "<th>Newsletter</th>";
     echo 
    "<th>Email</th>";
     echo 
    "<th>Geburtstag</th>";
     echo 
    "<th></th>";
     echo 
    "<th></th>";
    echo 
    "</tr>";
    while (
    $row mysql_fetch_array($result))
    {
      echo 
    "<tr>";
      echo 
    "<td>"$row['ID'] . "</td>";
      echo 
    "<td>"$row['Vorname'] . "</td>";
      echo 
    "<td>"$row['Nachname'] . "</td>";
      echo 
    "<td>"$row['PLZ'] . "</td>";
      echo 
    "<td>"$row['Ort'] . "</td>";
      echo 
    "<td>"$row['Strasse'] . "</td>";
      echo 
    "<td>"$row['Hausnr'] . "</td>";
      echo 
    "<td>"$row['Telnr'] . "</td>";
      echo 
    "<td>"$row['Newsletter'] . "</td>";
      echo 
    "<td>"$row['Email'] . "</td>";
      echo 
    "<td>"$row['Gebdatum'] . "</td>";
      echo 
    "<td id='tabelle'><a href='KLoeschen.php?var= ".$row['ID']."'><input type='submit' id='lief' name='loeschen' value='Löschen'</input></a></td>";
      echo 
    "<td id='tabelle'><a href='KBearbeiten.php?var= ".$row['ID']."'><input type='submit' id='lief' name='bearbeiten' value='Bearbeiten'</input></a></td>";
      echo 
    "</tr>";
    }
    echo 
    "</table>";

    ?>
    [/QUOTE][/SPOILER][/HIDE]
    Bis auf Sonderschüler kannst du alle Leute fragen - Saad ist PERFEKT wie 'ne Zeitform der deutschen Sprache.

Seite 3 von 3 Erste 123

Ähnliche Themen

  1. Antworten: 1
    Letzter Beitrag: 02.02.2014, 12:59
  2. Antworten: 4
    Letzter Beitrag: 12.07.2013, 10:53
  3. Problem Tabelle/Container
    Von Scarya im Forum HTML
    Antworten: 3
    Letzter Beitrag: 25.05.2013, 00:17
  4. HTML Tabelle Zeilenabstand
    Von Minecraft im Forum Webentwicklung
    Antworten: 15
    Letzter Beitrag: 03.10.2012, 09:22
  5. HTML5 + CSS3 - Blog Layout
    Von Snees im Forum HTML
    Antworten: 0
    Letzter Beitrag: 17.08.2012, 12:35
Diese Seite nutzt Cookies, um das Nutzererlebnis zu verbessern. Klicken Sie hier, um das Cookie-Tracking zu deaktivieren.