473,385 Members | 1,647 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Why is Netscape 6.1 disappearing my final table row?

I apologize for the length of the page below, but I've tried
to whittle it down as much as I can. The problem is that
Netscape 6.1 on my Win 2K Pro machine is disappearing
the final row of the table.

Opera 7.01 and IE 5 and 5.5 are both OK with the page, and
the offending line is right before the commented out alert line,
but I have been unable to figure why it's happening.

Thanks,
Csaba Gabor from New York

PS. While I am happy to have suggestions on ways to
improve the page (which I will eventually broach separately),
I am primarily intersted in understanding what is going on.

For those who are interested in making suggestions,
The intent of the page is to have the visible area of the
SCREEN filled with a TEXTAREA (to the extent possible)
while accomodating 5 uniformly sized buttons (each with
underlined accessKey. My code will do the uniform sizing)
to its right, with a line below the table and a few above. There
will be more stuff on the page below this, but I want the user
(me) to be able to see the entire TEXTAREA element
without scrolling.
This sounds pretty straightforward, but I've had lots of
problems getting agreement between Opera / IE / Netscape,
which is why you may see lamentable constructions like 4.5in.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML><HEAD>
<META http-equiv="content-type" content="text/html;charset=iso-8859-1">
<TITLE>Netscape demo</TITLE>
<STYLE type="text/css">
<!--
table#mytab td, table#mytab th {
border: 1px solid #000000; font-size: 75%; vertical-align:top;}
-->
</STYLE>
<SCRIPT type="text/javascript">
function uniformWidths(aButtons) {
// aButtons is either an array of buttons or a list of them.
// Makes them all the width of the widest one
var butt, i, myDiv, max = 0;
if (arguments.length>1) {
aButtons = [aButtons];
for (i=1;i<arguments.length;i++) aButtons[i] = arguments[i]; }
for (butt in aButtons)
if (aButtons[butt] && aButtons[butt].offsetWidth > max)
max = aButtons[butt].offsetWidth;
for (butt in aButtons) {
myDiv = aButtons[butt].getElementsByTagName("DIV")[0]
myDiv.style.width = max;
//alert(max + "\r\n" + aButtons[butt].innerHTML);
aButtons[butt].style.posWidth = max;
}
}
function allButtonsUniform (frm) {
var elem, aButts = [];
for (var i=0;i<frm.elements.length;i++) {
elem = frm.elements[i];
if (elem.type=="button") aButts[aButts.length] = elem; }
if (aButts.length>1) uniformWidths(aButts);
}
</SCRIPT>
</HEAD>
<BODY style="height:100%;padding:0;margin:0;border:solid 1px red"
onLoad='allButtonsUniform(document.forms[0])'>
<DIV style="height:95%;margin-left:.2in;border:solid 1px blue">
<BR><CENTER>Title goes here</CENTER><BR>
<FORM method=post action='index.php' name='Up'>
<TABLE id=mytab style='width:98%;border:solid 1px green'>
<TR>
<TD>Placeholder</td>
<TD align=right>Authorization:</TD>
<TD style='width:4%'><INPUT type=password size=24 name=jelszo></TD>
</TR><TR>
<TD rowspan=2 colspan=2><TEXTAREA
rows=36 cols=10 name=code style='width:100%'></TEXTAREA></TD>
<TD><BUTTON type=button><DIV>PHP / Script</DIV></BUTTON></TD>
</TR><TR>
<TD style='height:4.5in'><BUTTON type=button><DIV
Upload</DIV></BUTTON></TD>

</TR><TR>
<TD>This is</TD>
<TD>the last</TD>
<TD>row</TD>
</TR>
</TABLE>
</FORM></DIV></BODY></HTML>

Jul 20 '05 #1
3 1570
Is this more of a js question? Or css? You ought to pick one. Or at
least set followups. [I can't tell from the code posted, so I've
opted not to set them for the op.]

Csaba2000 wrote:
I apologize for the length of the page below, but I've tried
to whittle it down as much as I can.
Instead of posting code, how about uploading the html file somewhere
for us to test?
table#mytab td, table#mytab th {
border: 1px solid #000000; font-size: 75%; vertical-align:top;}


See the recent thread "my messy stylesheet just ain't..." for what's
wrong with your font-size declaration.

--
Brian
follow the directions in my address to email me

Jul 20 '05 #2
"Brian" <us*****@mangymutt.com.invalid-remove-this-part> wrote in message news:QINfb.679768$YN5.539190@sccrnsc01...
Is this more of a js question? Or css? You ought to pick one. Or at
least set followups. [I can't tell from the code posted, so I've
opted not to set them for the op.]

I'm sure I don't know. Otherwise, I wouldn't have cross posted
to both groups. It's clearly not a pure css issue since javascript
is required to show the problem. On the other hand, the offending
line involves .style (and, not being a css expert, to my mind css
and .style are pretty intertwined) and has more of a css type of
feel to me. I've never set followups, but from everything I've read,
if the responses don't appear in all the original groups, people
(including me) get annoyed because they don't see answers.
Although perhaps I misunderstand what you mean since I
haven't dealt with setting followups.
Csaba2000 wrote:
I apologize for the length of the page below, but I've tried
to whittle it down as much as I can.
Instead of posting code, how about uploading the html file somewhere
for us to test?


I often do both, but I almost always post the code. I do that for my
own benefit, because the web makes a great filing cabinet. To the
extent that others may see my work, too, and that I may forget the
details, I usually spend an hour or two carefully composing the example
to be minimal and illustrate the salient points in case I come back to
it much later.

Because of the length, I would normally provide a link, but I will be
moving within two days, and my server will be defunct for an
extended period till I am resettled. I prefer to minimize the amount
of mutterings about broken web links, especially considering that
the most amount of hits would come in the next several days.
table#mytab td, table#mytab th {
border: 1px solid #000000; font-size: 75%; vertical-align:top;}


Oops. My bad. I was doing some experimentation and forgot
to take that out.

Csaba
See the recent thread "my messy stylesheet just ain't..." for what's
wrong with your font-size declaration.

--
Brian
follow the directions in my address to email me


Jul 20 '05 #3
Yep
"Csaba2000" <ne**@CsabaGabor.com> wrote in message news:<bl********@dispatch.concentric.net>...
I apologize for the length of the page below, but I've tried
to whittle it down as much as I can.
60 lines isn't a long script, that's perfectly acceptable in a regular
post (beyond ~300 lines I believe that a link is better).
Netscape 6.1 on my Win 2K Pro machine is disappearing
the final row of the table.
I don't have NN6.1 here so cannot reproduce the problem (nor represent
it I'm afraid), but give a look at the following suggestions...
for (butt in aButtons)
You've got an array eventually, so you'd better use a normal iterator
rather than the for..in construction.
myDiv.style.width = max;
Incorrect here, "max" is filled with a double, while you need a string
and the appropriate css postfix:
myDiv.style.width = max + "px"
(and IIRC NN6.1 was affected by this)
<BODY style="height:100%;padding:0;margin:0;border:solid 1px red"
onLoad='allButtonsUniform(document.forms[0])'>


Better to use a CSS block declarations rather than inline declarations
IMHO, you'd gain in readibility.

As for your TEXTAREA sizing issue, I'm not sure of what the best
solution could be, maybe resize it according to the screen height and
its relative position, something like the following gives usable
results on IE6, Mozilla1.3 and Opera 7 (provided I've understood your
issue correctly), less the pre-load temp sizing (very important for
non-supporting UAs; the load delay might be a pain too).
<style type="text/css">html,body{margin:0;padding:0}</style>
<textarea id="foo"></textarea>
<script type="text/javascript">
function getPageHeight(w) {
var d=(w||(w=window)).document;
if(typeof w.innerHeight=="number") return w.innerHeight;
else if(d.documentElement && d.documentElement.clientHeight &&
d.compatMode && d.compatMode=="CSS1Compat")
return d.documentElement.clientHeight;
else if(d.body && d.body.clientHeight) return d.body.clientHeight;
return 0;
}

function getYPos(elem) {
var y=0;
if (typeof elem.offsetTop=="number")
do y += elem.offsetTop;
while (elem = elem.offsetParent);
return y;
}

window.onload = function (evt) {
if(document.getElementById) {
var ta = document.getElementById("foo"),
taTop = getYPos(ta),
winHeight = getPageHeight();
ta.style.height = (winHeight - taTop) + "px";
}
}
</script>
Regards,
Yep.
Jul 20 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Dom | last post by:
Hi, I am trying to get a dynamic table going. You click a button to add a row. In the newly created row a button to delete the row is placed (try the code example below). In Netscape, pressing...
3
by: Csaba2000 | last post by:
I apologize for the length of the page below, but I've tried to whittle it down as much as I can. The problem is that Netscape 6.1 on my Win 2K Pro machine is disappearing the final row of the...
1
by: Lee K. Seitz | last post by:
I've created a form and positioned the labels using CSS instead of a table for the first time. It looks good in IE 6, Opera 7, and Mozilla 1.6 (just downloaded; all Windows), but in Netscape 6 my...
4
by: Wm | last post by:
I have a script that changes a main/enlarged image when you click on a thumbnail. It works fine in IE, but for some reason it won't do anything in Netscape 7.1. Does anyone know if this is a...
3
by: VK | last post by:
<http://browser.netscape.com/ns8/> The biggest hecs: Two totally separate, including scripting, parsing engines: Mozilla/Firefox (called "Netscape") and Internet Explorer. User can choose any...
2
by: neptune | last post by:
I built a form to access a query with a 2 field primary key. It should use 2 controls to find the unique record and display the other field values on the form. In the criteria section of the...
3
by: Rick | last post by:
I have an interesting problem when I run the following code in Netscape (7.02) vs. IE. This page works great in IE and all my controls bring up the validation summary dialog box if the required...
6
by: qqq | last post by:
I'm a relative newbie... I'd like my site to support Netscape browsers. For a page I set 'TargetSchema' to 'IE 3.02/Netscape 3'. When I insert label or textbox web controls on the page, they...
2
by: Kevin Audleman | last post by:
I am using a hosted MSSQL 2000 database that powers the backend of my website. Website visitors interact with it via ASP pages I have developed. I also have an internal FileMaker 7 database that...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.