Forum Moderators: open

Message Too Old, No Replies

Closing tags in older browsers

Closing option tags prevent drop-downs from appearing in older browsers

         

rrhandle

7:43 pm on Oct 4, 2006 (gmt 0)

10+ Year Member



We have a web application developed in VS.NET 2003. Drop-downs having closing tags (see code below). When view in older browsers like Netscape 4.?, no drop-down appears; the selections are simple printed to the screen. Is there some work-around for this, or must we tell our customers to upgrade their browsers?

Thanks

<select name="ddlHeightFraction" id="ddlHeightFraction">
<option value="0.0">Fraction - Decimal</option>
<option value="0.0">0.0</option>
<option value="0.0625">1/16 - .0625 </option>
<option value="0.1250">1/8 - .1250 </option>
<option value="0.1875">3/16 - .1875 </option>
<option value="0.2500">1/4 - .2500 </option>
<option value="0.3125">5/16 - .3125 </option>
<option value="0.3750">3/8 - .3750 </option>
<option value="0.4375">7/16 - .4375 </option>
<option value="0.5000">1/2 - .5000 </option>
<option value="0.5625">9/16 - .5625 </option>
<option value="0.6250">5/8 - .6250 </option>
<option value="0.6875">11/16 - .6875 </option>
<option value="0.7500">3/4 - .7500 </option>
<option value="0.8125">13/16 - .8125 </option>
<option value="0.8750">7/8 - .8750 </option>
<option value="0.9375">15/16 - .9375</option>
<option value=""></option>

</select>

rocknbil

11:12 pm on Oct 4, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Welcome aboard rrhandle, although NN 4 was hopelessly buggy and you should **suggest** they upgrade, I have to say I don't think the problem is with the closing option tag. I've been using those since day one and never discovered a disappearing select list from the closing tags - I had the misfortune of working for a company who's CEO refused to use **anything** but NN and it was V4+ at the time, and I'm sure it would have come up. Have you tried putting one on a page by itself?

icantthinkofone

12:21 am on Oct 5, 2006 (gmt 0)

10+ Year Member



Does ANYBODY use NN4 anymore?

encyclo

1:10 am on Oct 5, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Welcome to WebmasterWorld, rrhandle. With regards to Netscape 4.x compatibility, here's an anecdote. I recently tried to install Netscape 4.79 just to test something. The new netscape.com home page (home.netscape.com is the default home page for NN4) actually crashes the browser immediately on loading - so unless you block your internet connection and manually change to the home page to something else, you get stuck in a loop - start the browser, crash, restart, crash...

The only people using Netscape 4.x these days are webmasters doing browser testing. There are very few major sites still supporting it, and if you try to surf with NN4 you will very soon give up in dispair. I haven't seen a NN4 user agent in my stats in 2006.

Your example markup is valid HTML, and should cause no problems in any major browser used today. You don't need to test Netscape (any version) now, as recent Netscape browsers are just rebadged Mozilla/Firefox.

jessejump

1:37 pm on Oct 5, 2006 (gmt 0)

10+ Year Member



Do you FORM tags in place?

penders

1:48 pm on Oct 5, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Drop-downs having closing tags (see code below). When view in older browsers like Netscape 4.?, no drop-down appears; the selections are simple printed to the screen. Is there some work-around for this...

As rocknbil surmised, the problem is not with the closing </OPTION> tags. To get a <SELECT> list to display as intended under Netscape 4 you need to enclose it in <FORM> tags!

<form action=""> 
....
</form>

Without the <FORM> tags, it displays as you've found... simply listed inline.

However, The <FORM> tags aren't required for valid HTML4.01.

Does ANYBODY use NN4 anymore?

Only in situations such as this! :)

...or must we tell our customers to upgrade their browsers?

Netscape 4?! I think yes! There'll probably be other things which aren't working too?!

-----
(Oops, jessejump beat me to it!)