Thanks bruno.
But the label "Version:" still appears little up when you shrink the width of the html page by your mouse.
...
thanks.
Main Topics
Browse All TopicsIn my HTML form I created table to have the testfield and labels but they do not stay in the same line. What is wrong..
***
<html>
<head>
<title>FASTT</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link rel="stylesheet" href="fastt.css" type="text/css">
</head>
<body bgcolor="#FFFFFF">
<form name="model_config_edit" method="post" action="menu.jsp?option=3.
<input type="hidden" name="w_config_id" value="1765">
<table width="90%" border="0" cellspacing="0" cellpadding="5" align="center">
<tr>
<td class="content_field_label
<hr size="1">
</td>
</tr>
<tr><td class="content_field_label
<td class="content_field_label
</tr>
<tr>
<td class="content_field_label
<hr size="1">
</td>
</tr>
<table width="70%" border="0" cellspacing="0" cellpadding="0" align="center">
<tr valign="bottom">
<td align="center" height="50">
<input type="submit" name="search" value="Continue" class="content_table_butto
</td>
<td align="center">
<input type="reset" name="reset" value="Reset" class="content_table_butto
</td>
</tr>
</table>
</table>
</form>
</html>
***
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
note: its generally not a good idea to use fixed width tables because they may not format correctly at different resolutions (eg. a table with a width of say 900 would look ok at a res of 1024*768 but would be too big at 800*600). sizing a table based on percentage on the other hand will obviously size correctly and fit well at any resolution
try a nested table
<html>
<head>
<title>FASTT</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link rel="stylesheet" href="fastt.css" type="text/css">
</head>
<body bgcolor="#FFFFFF">
<form name="model_config_edit" method="post" action="menu.jsp?option=3.
<input type="hidden" name="w_config_id" value="1765">
<table width="90%" border="0" cellspacing="0" cellpadding="5" align="center">
<tr>
<td class="content_field_label
</tr>
<tr>
<td class="content_field_label
<td class="content_field_label
<td class="content_field_label
<!-- Add second table here -->
<table>
<tr>
<td valign="top"><b>Version:</
<td valign="top"><input type="text" name="V_3" size="25" maxlength="50" value=""></td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="content_field_label
</tr>
<tr>
<td colspan="3">
<table width="70%" border="0" cellspacing="0" cellpadding="0" align="center">
<tr>
<td align="center" height="50"><input type="submit" name="search" value="Continue" class="content_table_butto
<td align="center"><input type="reset" name="reset" value="Reset" class="content_table_butto
</tr>
</table>
</td>
</tr>
</table>
</form>
</html>
>>its generally not a good idea to use fixed width tables because they may not format correctly at different resolutions (eg. a table with a width of say 900 would look ok at a res of 1024*768 but would be too big at 800*600). sizing a table based on percentage on the other hand will obviously size correctly and fit well at any resolution
so how about a compromise?
<html>
<head>
<title>FASTT</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link rel="stylesheet" href="fastt.css" type="text/css">
<script>
var isNS = (document.layers ? true : false);
function reSizeTable(){
x=600;
if(screen.availWidth>600){
x=screen.availWidth-50;
}
document.getElementById('r
}
function setLocation(){
if(isNS){
window.location=winLoc;
window.location.reload();
}
}
window.onload=reSizeTable;
window.onresize=setLocatio
</script>
</head>
<body bgcolor="#FFFFFF">
<form name="model_config_edit" method="post" action="menu.jsp?option=3.
<input type="hidden" name="w_config_id" value="1765">
<table id="reTable" cellspacing="0" cellpadding="0" width="600">
<tr>
<td>
<table width="90%" border="0" cellspacing="0" cellpadding="5" align="center">
<tr>
<td class="content_field_label
<hr size="1">
</td>
</tr>
<tr><td class="content_field_label
<td class="content_field_label
</tr>
<tr>
<td class="content_field_label
<hr size="1">
</td>
</tr>
<table width="70%" border="0" cellspacing="0" cellpadding="0" align="center">
<tr valign="bottom">
<td align="center" height="50">
<input type="submit" name="search" value="Continue" class="content_table_butto
</td>
<td align="center">
<input type="reset" name="reset" value="Reset" class="content_table_butto
</td>
</tr>
</table>
</table>
</td>
</tr>
</table>
</form>
</html>
True you could use Javascript to get the window size but you don't need to change the size of the table or the cell's within the table. Besides javascript has browser limitations.
the goal is to align the text on the same horizontal line and this can be done in HTML 4 with a nested table and the cell's vertical alignment set to top.
This will add a few lines of code to your page but it's not browser dependant and should work in most HTML 4 compatible browsers
tis true..
however not all borwsers support XHTML1.1 or CSS 2
and well, borwser issues are a topic for another discussion :)
Agreed that tables were not 'made' for layout howerver they do acomplish this task without worring about browser compatibility.
not the "best" practice to use tables but effective in this case.
Business Accounts
Answer for Membership
by: brunobearPosted on 2003-12-30 at 09:13:57ID: 10017110
skundu,
1.3"> " valign="top" colspan="3"> " width="100" valign="bottom"><b>Softwar e:</b> </td> <td class="content_field_label " valign="bottom" width="100">E380AS_G_0A.03 .20R </td>
" valign="bottom"><b>Version :</b> <input type="text" name="V_3" size="25" maxlength="50" value=""></td>
" valign="top" colspan="3"> n"> n">
try this:
<html>
<head>
<title>FASTT</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<link rel="stylesheet" href="fastt.css" type="text/css">
</head>
<body bgcolor="#FFFFFF">
<form name="model_config_edit" method="post" action="menu.jsp?option=3.
<input type="hidden" name="w_config_id" value="1765">
<table width="90%" border="0" cellspacing="0" cellpadding="5" align="center">
<tr>
<td class="content_field_label
<hr size="1">
</td>
</tr>
<tr><td class="content_field_label
<td class="content_field_label
</tr>
<tr>
<td class="content_field_label
<hr size="1">
</td>
</tr>
<table width="70%" border="0" cellspacing="0" cellpadding="0" align="center">
<tr valign="bottom">
<td align="center" height="50">
<input type="submit" name="search" value="Continue" class="content_table_butto
</td>
<td align="center">
<input type="reset" name="reset" value="Reset" class="content_table_butto
</td>
</tr>
</table>
</table>
</form>
</html>
bruno