By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,766 Members | 1,261 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,766 IT Pros & Developers. It's quick & easy.

Mozilla User Agent ID

P: n/a

Does the Mozilla browser even support CSS?
Very few of my stylesheet formats work in Mozilla.

Is there a local stylesheet that is overriding my stylesheet?
If so, is there an option to turn off the local stylesheet?

Also, I would treat Mozilla like Netscape 4.x in my PHP code; however, I
can't see in the user agent (shown below) any way to
determine that the browser is Mozilla. I've seen other browser
user agents with "Gecko" in them and those browsers do support style sheets.

Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.5) Gecko/20031007
--
Don Adams
Jul 20 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
Don Adams wrote:
Does the Mozilla browser even support CSS?
Of course - better than most (all?) other browsers.

Very few of my stylesheet formats work in Mozilla.
Then you are probably doing something wrong. Supply a URL and perhaps
somebody can point the problem out to you. A common problem is serving
your stylesheets with the wrong content-type. Alternatively, you can check
your HTML and CSS for syntax errors here:

<URL:http://validator.w3.org/>
<URL:http://jigsaw.w3.org/css-validator/>

Is there a local stylesheet that is overriding my stylesheet?
There are three types of stylesheet - author stylesheets, user stylesheets
(which Mozilla won't use unless you explicitly configure it to), and
user-agent stylesheets (the default presentation). These /cascade/
together (hence the name Cascading Style Sheets) to give the final
presentation.

It's very unlikely that a user stylesheet or user-agent stylesheet is the
source of your problems.

Also, I would treat Mozilla like Netscape 4.x in my PHP code;
Why? There's practically no common behaviour between them.

however, I can't see in the user agent (shown below) any way to
determine that the browser is Mozilla. I've seen other browser
user agents with "Gecko" in them and those browsers do support style
sheets.
Gecko is the rendering engine used by Mozilla, Firebird, Netscape, etc.
Gecko is the piece of software that applies stylesheets, so you are
probably just looking at different versions of Gecko.

If I had to guess, I'd say that you are serving your stylesheets with an
incorrect content-type, and they only get applied by older versions of
Gecko, or it varies depending on whether you are kicking it into "quirks
mode" or "standards-compliant mode". Supply a URL if you can't figure it
out by yourself.

Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.5) Gecko/20031007


User-agent sniffing is usually a case of trying to fix the symptom and not
the problem. Apart from anything else, it's inherently unreliable and
should only be used as a last resort.
--
Jim Dabell

Jul 20 '05 #2

P: n/a
"Don Adams" <dg*@sgi.com> wrote:
Does the Mozilla browser even support CSS?
One of the best.
Very few of my stylesheet formats work in Mozilla.
Probably something wrong with your stylesheet then. Post a URL of the
web site in question so we can check it out.
Is there a local stylesheet that is overriding my stylesheet?
If so, is there an option to turn off the local stylesheet?
Only if you (or whomever uses this particular copy of Mozilla) have
set one up. Look for a file called user.css
Also, I would treat Mozilla like Netscape 4.x in my PHP code;
NN4.x is an antique dinosaur with many, many bugs and deficencies.
Mozilla is a cutting edge, state of the art browser with some of the
best support for web standards around.
however, I
can't see in the user agent (shown below) any way to
determine that the browser is Mozilla. I've seen other browser
user agents with "Gecko" in them and those browsers do support style sheets.

Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.5) Gecko/20031007


Gecko os the name of the rendering engine used in Mozilla, Netscape
6+, Camino, etc., etc. They all render pages much the same.

Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don't like my tie." - The Doctor

Steve Pugh <st***@pugh.net> <http://steve.pugh.net/>
Jul 20 '05 #3

P: n/a
It seems "Don Adams" wrote in
comp.infosystems.www.authoring.stylesheets in article
<bu************@fido.engr.sgi.com>:
Does the Mozilla browser even support CSS?
Yes, of course -- and rather better than most of the the
alternatives.
Very few of my stylesheet formats work in Mozilla.


URL? Details? (Please validate your stylesheet at
<http://www.htmlhelp.org/tools/csscheck/> and fix any errors first.)

--
Stan Brown, Oak Road Systems, Cortland County, New York, USA
http://OakRoadSystems.com/
HTML 4.01 spec: http://www.w3.org/TR/html401/
validator: http://validator.w3.org/
CSS 2 spec: http://www.w3.org/TR/REC-CSS2/
2.1 changes: http://www.w3.org/TR/CSS21/changes.html
validator: http://jigsaw.w3.org/css-validator/
Jul 20 '05 #4

P: n/a
"Don Adams" <dg*@sgi.com> wrote in
news:bu************@fido.engr.sgi.com:
Also, I would treat Mozilla like Netscape 4.x in my PHP code; however,
I can't see in the user agent (shown below) any way to
determine that the browser is Mozilla.


Take a different approach, because you can't rely on what you are doing.

For example, many people use Norton Internet Security, and it has a
'Browser Privacy' option:
Browser Privacy prevents Web sites from learning the type of computer
and browser that you are using, the Web site that you last visited,
and other information about your browsing habits
and that's just an example of what "non technical people" can do.
Many people can, and do, make their browsers appear to be other than
what they are actually using, for a variety of reasons.

--
Dave Patton
Canadian Coordinator, the Degree Confluence Project
http://www.confluence.org dpatton at confluence dot org
My website: http://members.shaw.ca/davepatton/
Vancouver/Whistler - host of the 2010 Winter Olympics
Jul 20 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.