Vote count:
0
I'm working on a HTML page which I intend to use with PHP later however I have encountered some issues with the height scaling.
My tables and also the elements within the tables are not abiding by the height limits I have set within a container.
I do not want it to extend beyond the page as that would require a scroll bar. Anybody have any suggestions?
Code HTML:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://ift.tt/kkyg93">
<html xmlns="http://ift.tt/lH0Osb">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title>Untitled Document</title>
<link rel="stylesheet" type="text/css" href="summonerTable.css"/>
<link rel="stylesheet" type="text/css" href="navBar.css"/>
</head>
<body>
<div class="summonerContainer">
<div class="navbar">
</div>
<div id="gameDetails">
</div>
<table border="1" id="summonerTeams">
<tr height="100%">
<!-- Begin Definitions !-->
<td>
<table width="100%" id="summonerTeamsDetails" height="100%">
<tr height="5%">
<td width="100%" bgcolor="red">
<p>
Summoner Name
</p>
</td>
</tr>
<tr height="10%">
<td>
<table width="100%" height="100%" id="summonerTeamDetailsInterior" bgcolor="red">
<tr>
<!-- <td width="50%" background="ChampionIcon.png" id="summonerImg" alt="Hello">-->
<td width="25%" bgcolor="aqua">
<img src="ChampionIcon.png" id="summonerImg2" alt="Hello"/>
</td>
<td width="12%">
<table height="100%" width="100%" id="summonerTeamDetailsInterior" bgcolor="aqua">
<tr>
<!-- <td background="summonerSpell.png" id="summonerImg">-->
<td style="vertical-align:bottom;">
<img src="summonerSpell.png" id="summonerImg" alt="Hello"/>
</td>
</tr>
<tr>
<!-- <td background="summonerSpell.png" id="summonerImg"> -->
<td style="vertical-align:top;">
<img src="summonerSpell.png" id="summonerImg" alt="Hello"/>
</td>
</tor>
</table>
</td>
<td width="75%">
<table height="100%" width="100%" id="summonerTeamDetailsInterior" bgcolor="red">
<tr>
<td bgcolor="black">
<p>
tryndamere
</p>
</td>
</tr>
<tr>
<td>
<p>
K/D/A: 1000/1000/1000
</p>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr height="10%">
<td width="100%" bgcolor="red">
<p>
Champion Games
</p>
</td>
</tr>
<tr height="5%">
<td width="100%" bgcolor="red">
<p>
KDR
</p>
</td>
</tr>
<tr height="10%">
<td width="100%" bgcolor="red">
<p>
Ranking
</p>
</td>
</tr>
<tr height="5%">
<td width="100%" bgcolor="red">
<p>
Series
</p>
</td>
</tr>
<tr height="10%">
<td width="100%" bgcolor="red">
<p>
Runes
</p>
</td>
</tr>
<tr height="10%">
<td width="100%" bgcolor="red">
<p>
Masteries
</p>
</td>
</tr>
<tr height="10%">
<td width="100%" bgcolor="red">
<p>
Ranked Wins
</p>
</td>
</tr>
<tr height="5%">
<td width="100%" bgcolor="red">
<p>
Normal Wins
</p>
</td>
</tr>
<tr height="10%">
<td width="100%" bgcolor="red">
<p>
Show Champion Counters
</p>
</td>
</tr>
</table>
</td>
<!-- End Definitions !-->
<td>
<p>
AAAAAAAAAAAAAAAA
</p>
</td>
<td>
<p>
AAAAAAAAAAAAAAAA
</p>
</td>
<td>
<p>
AAAAAAAAAAAAAAAA
</p>
</td>
<td>
<p>
AAAAAAAAAAAAAAAA
</p>
</td>
</tr>
</table>
<div id="summonerMiddleBar">
</div>
<table border="1" id="summonerTeams">
<!-- Summoner Details Table (2) !-->
<tr height="100%">
<!-- Begin Definitions !-->
<td>
<table width="100%" id="summonerTeamsDetails" height="100%">
<tr height="5%">
<td width="100%" bgcolor="red">
<p>
Summoner Name
</p>
</td>
</tr>
<tr height="20%">
<td>
<table width="100%" height="100%" id="summonerTeamDetailsInterior" bgcolor="red">
<tr>
<!-- <td width="50%" background="ChampionIcon.png" id="summonerImg" alt="Hello">-->
<td width="25%" bgcolor="aqua">
<img src="ChampionIcon.png" id="summonerImg2" alt="Hello"/>
</td>
<td width="12%">
<table height="100%" width="100%" id="summonerTeamDetailsInterior" bgcolor="aqua">
<tr>
<!-- <td background="summonerSpell.png" id="summonerImg">-->
<td style="vertical-align:bottom;">
<img src="summonerSpell.png" id="summonerImg" alt="Hello"/>
</td>
</tr>
<tr>
<!-- <td background="summonerSpell.png" id="summonerImg"> -->
<td style="vertical-align:top;">
<img src="summonerSpell.png" id="summonerImg" alt="Hello"/>
</td>
</tr>
</table>
</td>
<td width="75%">
<table height="100%" width="100%" id="summonerTeamDetailsInterior" bgcolor="red">
<tr>
<td bgcolor="black">
<p>
tryndamere
</p>
</td>
</tr>
<tr>
<td>
<p>
K/D/A: 1000/1000/1000
</p>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr height="10%">
<td width="100%" bgcolor="red">
<p>
Champion Games
</p>
</td>
</tr>
<tr height="5%">
<td width="100%" bgcolor="red">
<p>
KDR
</p>
</td>
</tr>
<tr height="10%">
<td width="100%" bgcolor="red">
<p>
Ranking
</p>
</td>
</tr>
<tr height="5%">
<td width="100%" bgcolor="red">
<p>
Series
</p>
</td>
</tr>
<tr height="10%">
<td width="100%" bgcolor="red">
<p>
Runes
</p>
</td>
</tr>
<tr height="10%">
<td width="100%" bgcolor="red">
<p>
Masteries
</p>
</td>
</tr>
<tr height="10%">
<td width="100%" bgcolor="red">
<p>
Ranked Wins
</p>
</td>
</tr>
<tr height="5%">
<td width="100%" bgcolor="red">
<p>
Normal Wins
</p>
</td>
</tr>
<tr height="10%">
<td width="100%" bgcolor="red">
<p>
Show Champion Counters
</p>
</td>
</tr>
</table>
</td>
<!-- End Definitions !-->
<td>
<p>
AAAAAAAAAAAAAAAA
</p>
</td>
<td>
<p>
AAAAAAAAAAAAAAAA
</p>
</td>
<td>
<p>
AAAAAAAAAAAAAAAA
</p>
</td>
<td>
<p>
AAAAAAAAAAAAAAAA
</p>
</td>
</tr>
</table>
<div class="footer">
</div>
</div>
</body>
</html>
CSS Code:
@charset "utf-8";
/* CSS Document */
html, body
{
height:100%;
width:100%;
font:"Courier New", Courier, monospace;
color:white;
}
.summonerContainer
{
width:100%;
height:100%;
padding:0;
margin:0;
resize:none;
}
#summonerTeams
{
width:100%;
margin:0;
padding:0;
table-layout:fixed;
padding:0;
margin:0;
border-collapse:collapse;
height:38%;
}
#summonerTeamsDetails
{
padding:0;
margin:0;
border-spacing:0;
}
#summonerTeamDetailsInterior
{
padding:0;
margin:0;
border-spacing:0;
border-collapse:collapse;
}
#summonerMiddleBar
{
background-color:#000;
color:white;
height:5%;
width:100%;
}
#gameDetails
{
background-color:aqua;
color:white;
height:5%;
width:100%;
}
p
{
font-size:1.5vw;
margin:0;
padding:0;
text-align:center;
}
body
{
padding:0;
margin:0;
}
#summonerImg
{
max-width:100%;
width:100%;
background-size:cover;
/*display:block;*/
}
#summonerImg2
{
max-width:100%;
width:100%;
background-size:cover;
/*display:block;*/
}
table
{
}
Other CSS Code: @charset "utf-8"; /* CSS Document */ .navbar
{
background-color:#000;
color:white;
height:10%;
width:100%;
}
.footer
{
background-color:#000;
color:white;
height:4%;
width:100%;
}
asked 42 secs ago
Table Not Obeying Container Heights
Aucun commentaire:
Enregistrer un commentaire