473,799 Members | 3,098 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Inconsistent Display in Different Browsers

I noticed that that <ul> lists display differently with <br> between
<li>s in IE and Mozilla.

Does anyone know of a reference that catalogs all of the known types
of differences in display between browsers? Or do you all just do
multiple tests of all your pages?

Thanks in advance for any advice.
_______________ _______________ ___________

Center For Practical Self Defense
Riverside, California
www.centerforpracticalselfdefense.com
Dec 8 '05 #1
6 2490
Doug Mazzacua wrote:

I noticed that that <ul> lists display differently with <br> between
<li>s in IE and Mozilla.

Does anyone know of a reference that catalogs all of the known types
of differences in display between browsers? Or do you all just do
multiple tests of all your pages?

Thanks in advance for any advice.


I generally test first by viewing my page with Mozilla Suite and
then validating it with the W3C tools:
<http://validator.w3.or g/> for HTML
<http://jigsaw.w3.org/css-validator/> for CSS
Thus, I verify that both the design and syntax of the page are
correct.

I tried using <br> within list items. With Mozilla, the page
appears as I would expect. Since the HTML and CSS validate without
errors, I must assume that any anomalous appearance with another
browser is a problem with that browser.

--

David E. Ross
<http://www.rossde.com/>

I use Mozilla as my Web browser because I want a browser that
complies with Web standards. See <http://www.mozilla.org/>.
Dec 8 '05 #2
Doug Mazzacua wrote:

I noticed that that <ul> lists display differently with <br> between
<li>s in IE and Mozilla.


What are the line breaks doing there in the first place? If they are for
presentation purposes, you should use margin-bottom on the li element
instead. Besides being The Right Thing to do, results will likely be
more consistent across browsers.

--
Reply email address is a bottomless spam bucket.
Please reply to the group so everyone can share.
Dec 8 '05 #3
On Wed, 07 Dec 2005 19:06:28 -0800, Doug Mazzacua <d_*****@surfbe st.net>
wrote:
I noticed that that <ul> lists display differently with <br> between
<li>s in IE and Mozilla.
This isn't valid HTML, so don't do it.

It's hard enough keeping _valid_ HTML consistent, so if you start coding
invalid stuff, then it really becomes impossible. You're relying on one
browser's particular handling of an undocumented error condition, so
there's no reason at all why another browser should look anything like
it.

For the concept of "validity", then search back in this newsgroup. Also
investigate using on-line validators like http://validator.w3.org and
begin learning to understand what a HTML DTD is.

As to your specific example, then learn a little CSS and look at the
margin properties.
Does anyone know of a reference that catalogs all of the known types
of differences in display between browsers?
Not really practical to do. There are sites that list the major problems
and obvious errors in a particular browser, but the problem space of
"compare every browser for every situation" is just too large to ever
quantify the variations in. Try searching for "browser CSS error" and
"box model" just for starters.

As an example, the rendering of a simple web page varies between IE and
Firefox depending not only on the screen size, but on the default font
size selected by the windows desktop (the "Large Fonts" setting). This
is a clear bug in IE (it incorrectly applies a scaling twice, so "small
fonts" actually become larger) but it's so removed from "the web tools"
that a website has no _possible_ control over it. You can't "fix" this,
but you can certainly waste a lot of effort trying to.

Or do you all just do
multiple tests of all your pages?


Doing single tests is good. Doing multiple tests is impossible. You
have to do single tests against the _standard_, because it's objective
(if not always entirely helpful). Testing against all the possible
combinations of browser-specific behaviour is just too open-ended to be
practical.

I recently had a realistically 3 month project and a 2 month timescale
to do it in. It took me 3 months in total to get the client happy with
it, the last month of over-run being almost entirely taken up with
chasing after trivial browsers inconsistencies . This cost them 50% on
their costs and made a site that was actually _less_ good than it had
been a month earlier. However certain things were now more accurately
aligned on different browsers, even though no-one was ever going to look
at it on two browsers side-by-side. If you go down this route of "It
must look identical everywhere" then you'll find that it's expensive,
pointless and even harmful.
Dec 8 '05 #4
Andy Dingley wrote [in part]:

On Wed, 07 Dec 2005 19:06:28 -0800, Doug Mazzacua <d_*****@surfbe st.net>
wrote:
I noticed that that <ul> lists display differently with <br> between
<li>s in IE and Mozilla.


This isn't valid HTML, so don't do it.


A test page with <br> breaks within the text following an <li> tag
passed validation as HTML 4.01 transitional at
<http://validator.w3.or g/>.

--

David E. Ross
<http://www.rossde.com/>

I use Mozilla as my Web browser because I want a browser that
complies with Web standards. See <http://www.mozilla.org/>.
Dec 8 '05 #5
On Thu, 08 Dec 2005 15:45:56 -0800, David Ross <no****@nowhere .not>
wrote:
>I noticed that that <ul> lists display differently with <br> between
><li>s in IE and Mozilla.


This isn't valid HTML, so don't do it.


A test page with <br> breaks within the text following an <li> tag
passed validation as HTML 4.01 transitional at
<http://validator.w3.or g/>.


This is why it's helpful if the original poster includes a URL !
This is invalid HTML
<ul>
<li>Foo</li>
<br>
<li>Bar</li>
</ul>

This (as I think you tested) is valid HTML
<ul>
<li>Foo
<br>
<li>Bar
</ul>

It's actually equivalent (when parsed) to the following.
<ul>
<li>Foo
<br></li>
<li>Bar</li>
</ul>
Which I think you'll see is _not_ the same as the 1st example.

Now I can't know what the OP was actually using. But I strongly suspect
they've been using the 1st invalid case, because that's the one I'd most
expect to show up browser variations.
Dec 9 '05 #6
On Thu, 8 Dec 2005, David Ross wrote:
Andy Dingley wrote [in part]:

On Wed, 07 Dec 2005 19:06:28 -0800, Doug Mazzacua <d_*****@surfbe st.net>
wrote:
I noticed that that <ul> lists display differently with <br> between
<li>s in IE and Mozilla.


This isn't valid HTML, so don't do it.


A test page with <br> breaks within the text following an <li> tag


Of course. Re-read the above - it says "between" li, not within. So
you changed the topic, and threw no new light on the original problem,
whatever it might have really been. Needless to say, the original
poster should have offered the URL of some specimen page to illustrate
their question - bonus points for saying what they were hoping to
achieve, and what actually happened in the browser they tried.

To the O.P, I would have to say that different renderings in different
browsers is something which comes with the territory - it's a feature
of the web. But there are ways of helping to get reasonably
consistent rendering in the usual graphical browser situation, and I'd
say the most widely-applicable rule to apply across the board (with
only minuscule exceptions) is to conform to applicable interworking
rules.

Over and above that: when lists are involved, the stylesheet should
not try to set isolated values for border-left and/or margin-left on
ul, ol, li. If any of those properties is specified, then all of them
should be. The reason, obviously, is that different browsers use
different defaults, even when the end result looks much the same.

<br> as a means of inserting vertical white space should basically
never be used nowadays (if it ever should have been used for that
purpose, which I might dispute). The defined purpose for <br> is to
break a line - nothing more. Use it that way, or don't use it at all.
Dec 20 '05 #7

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

Similar topics

2
1858
by: Graham J | last post by:
Hello, Apologies for the somewhat wordy and garbled subject as I couldn't think how to phrase it and this has hindered my searching for any previous answers. It could be a really simple question. Anyway... I have a simple javascript function that opens up a new window and writes HTML code in it to display an image (I don't just display the image because of problems with different margins in different browsers). Nothing exotic there. ...
1
1690
by: The Pistoleer | last post by:
I have an inconsistent problem with some Internet pages when using Netscape (7.1) that I cannot reproduce with IE nor locally. Below is an example link. There are several tables on the pages. The tables at the top containing small images are working correctly. The tables below that contain product descriptions and input to purchase an item, these table have a problem with Netscape. Sometimes one or more of these tables will just...
4
3074
by: David Ehmer | last post by:
I have some buttons I'm working on at this address http://www.boatingaccessories.com.au/test3.htm In NS7, Mozilla and Opera, the borders don't render. IE6 displays as intended. Appreciate any insights. David
1
1486
by: Paul Cowan | last post by:
Although new to .net, I am in the process of developing a web application in vs.net 2003. When run on the 'development' machine the various controls have a XP look about them (ie flat buttons, text boxes, etc). When the application is transferred to another machine (same operating system) the controls have a more traditional 3d look about them. The size and position of some of the controls is different.
5
1525
by: scott | last post by:
I'm trying to display a small "color square" to the left of each combo box choice. I know I can make each choice have a different background color, but is it possible to display a background image for each row? In my code below, I'm trying to display img_color1.gif which is a 5 pixel wide by 10 pixel high transparent gif with a small color square on the background of a choice. My end goal is to have an Outlook looking combo box like the...
2
1213
by: MR. UNDERHILL | last post by:
I image this question is already answer in thousands of places because is very obvious that ocurrs. Basically, I have a .net text box control on a asp.net page, and I'm using the width property to specify it's display size, it works great in Internet Explorer 6.0 but running the same page on Netscape 7.1 doesn't work. To make it work I'm setting the <input> size property by hand on the PreRender event of the page, but I wonder is there is...
10
1492
by: Robert Baer | last post by:
<SWM.HTM listing; does not work; positioning wrong (below main GIF)> <!-- IE adds a horizontal 4-icon strip near the upper left corner when that area is visited (WTF?) --> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <title>Stripper wells and production</title> </head> <SCRIPT LANGUAGE="JavaScript"> <!--
25
2480
by: Dave | last post by:
Hello. In trying to get an anchor element to stylistically match an input or button element, I find that the button and input cannot be styled according to the 2.1 CSS spec. For example, I expected this ruleset: ..but { display: block; background-color: red; font-size: 14px; text-decoration: none; line-height: 16px; width: auto; height: 16px; padding: 0; margin: 0;
17
2313
by: Dudely | last post by:
My web page displays just fine under IE7, but under IE6 about 90% of it is just plain missing. I get the top of the page, and the bottom of the page... but not the middle. I have not tested with any other browsers. The page is at www.greengoldcapital.com I use considerable amounts of CSS, and a lot of other things including javascript, SSI, PHP, mySQL, and a partridge in a pear tree. I have a third party application integrated in,...
0
9541
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10482
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10251
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
10027
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9072
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7564
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5463
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5585
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3759
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.