473,396 Members | 2,140 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,396 software developers and data experts.

XML & NN7

Hi!

I can't get a simple XML document to display in Netscape Navigator 7. Am I
doing something wrong?
TIA
Jul 20 '05 #1
6 1862

In article <cu*******************@newsread1.prod.itd.earthlin k.net>,
ar********@earthlink.net says...
I can't get a simple XML document to display in Netscape Navigator 7. Am I
doing something wrong?


What MIME type is your web server providing for the XML file? I believe
text/xml is appropriate (or is it application/xml?). I know that Mozilla
is fussy about this matter. In some configurations of Apache, at least,
there is no MIME type declared for *.xml files and the result is that
Mozilla doesn't know they are XML and won't process them appropriately.
I'm assuing NN is the same story.

Peter

Jul 20 '05 #2
On Sun, 20 Jul 2003 11:59:04 GMT, "Alan Whitener"
<ar********@earthlink.net> wrote:
I can't get a simple XML document to display in Netscape Navigator 7. Am I
doing something wrong?

Yes.

Netscape 7 (ie. Mozilla) displays XML perfectly correctly - which
means that you probably don't know what "perfectly correctly" means in
this context

It means the text nodes. And I bet that is what you see. What you
probably _want_ to know is "why doesn't it look like it does on MSIE?"

And the answer to that is that MSIE does _not_ display XML unformatted
(which is what Netscape does) - it does it through an in-built XSLT
script. Theirs, unless you provide your own.
--
Mark A. Preston, The Magpie's Nest, Lancashire, UK
Website : www.magpiesnest.co.uk
Jul 20 '05 #3
"Mark Preston" <us****@noemailaddress.co.uk> schrieb im Newsbeitrag
news:sj********************************@4ax.com...
On Tue, 22 Jul 2003 13:45:08 GMT, "Alan Whitener"
<ar********@earthlink.net> wrote:
Sounds right. It does just display the flat xml file. But I define a XSL:<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="index_gallery01.xsl"?>
It just doesn't use it, or so it seems. Does the file extension (xslt vs.xsl) make any difference?

Got to say, so far I have only used raw XML and CSS in Netscape and
have not yet tried the XSLT - but they do keep saying it works, and I
trust them that far at least.

Have you tried submitting the XSL to the W3C validator to see if there
are any problems? Failing that - does it work locally on your own PC
and does the same stylesheet work when you run it through a processor
like Saxon or xsltproc?

Anyone else have any ideas why an XSL wouldn't work in Netscape 7?


Maybe #1 on http://www.mozilla.org/projects/xslt/faq.html?
Jul 20 '05 #4
Mark Preston <us****@noemailaddress.co.uk> writes:
On Tue, 22 Jul 2003 13:45:08 GMT, "Alan Whitener"
<ar********@earthlink.net> wrote:
Sounds right. It does just display the flat xml file. But I define a XSL:
<?xml version="1.0"?>
<?xml-stylesheet type="text/xsl" href="index_gallery01.xsl"?>
It just doesn't use it, or so it seems. Does the file extension (xslt vs.
xsl) make any difference?
.... Have you tried submitting the XSL to the W3C validator to see if there
are any problems? Failing that - does it work locally on your own PC
and does the same stylesheet work when you run it through a processor
like Saxon or xsltproc?

Anyone else have any ideas why an XSL wouldn't work in Netscape 7?


Yes. As has been mentioned, Mozilla is picky about MIME types.
I assume that NN inherits this pickiness. If you're seeing the
flat XML file, I would guess that one or more of the following is
the case:

(a) your XML is being served as text/plain (use View / Page Info
to find out for sure)
(b) your XSL is being served with a MIME type Mozilla doesn't like.
If I recall correctly, application/xml and text/xml work fine, but
if your server administrator looked too hard at the xml-stylesheet
processing instruction and decided to serve XSL as text/xsl, Mozilla
won't be happy. (At least, this is my diagnosis of a problem I
encountered recently; once I changed from text/xsl to application/xml
it all started working.)

-C. M. Sperberg-McQueen
World Wide Web Consortium

Jul 20 '05 #5
On Sat, Jul 25, C. M. Sperberg-McQueen inscribed on the eternal scroll:
Yes. As has been mentioned, Mozilla is picky about MIME types.


In general I would interpret that as a mandatory requirement of the
applicable HTTP RFC (currently 2616), rather than "pickyness". "If
and only if" the server does not provide a content-type, is the client
software permitted to guess. (But the server "should" always provide
an appropriate content-type.)

If the server presents a content-type that the client considers
inappropriate, then it could be permissible to consult with the user
about an error fixup, but it's impermissible, according to RFC2616,
for the software to silently DWIM. Mozilla is behaving correctly,
according to this general principle.

Any client software which fails to conform with this requirement
represents an unnecessary extra security exposure, and is in violation
of the interworking specification, as I interpret it. There are
several demonstration pages around which demonstrate this
vulnerability in IE.

(That's the general position. I'm not arguing with what you said
about the specifics of text/xsl, OK?).

best regards
Jul 20 '05 #6
"Alan J. Flavell" <fl*****@mail.cern.ch> writes:
On Sat, Jul 25, C. M. Sperberg-McQueen inscribed on the eternal scroll:
Yes. As has been mentioned, Mozilla is picky about MIME types.


In general I would interpret that as a mandatory requirement of the
applicable HTTP RFC (currently 2616), rather than "pickyness".


Point taken. My word choice was off.

-C. M. Sperberg-McQueen
Jul 20 '05 #7

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

Similar topics

9
by: Collin VanDyck | last post by:
I have a basic understanding of this, so forgive me if I am overly simplistic in my explanation of my problem.. I am trying to get a Java/Xalan transform to pass through a numeric character...
1
by: DrTebi | last post by:
Hello, I have the following problem: I used to "encode" my email address within links, in order to avoid (most) email spiders. So I had a link like this: <a...
0
by: Thomas Scheffler | last post by:
Hi, I runned in trouble using XALAN for XSL-Transformation. The following snipplet show what I mean: <a href="http://blah.com/?test=test&amp;test2=test2">Test1&amp;</a> <a...
4
by: Luklrc | last post by:
Hi, I'm having to create a querysting with javascript. My problem is that javscript turns the "&" characher into "&amp;" when it gets used as a querystring in the url EG: ...
4
by: johkar | last post by:
When the output method is set to xml, even though I have CDATA around my JavaScript, the operaters of && and < are converted to XML character entities which causes errors in my JavaScript. I know...
8
by: Nathan Sokalski | last post by:
I add a JavaScript event handler to some of my Webcontrols using the Attributes.Add() method as follows: Dim jscode as String = "return (event.keyCode>=65&&event.keyCode<=90);"...
11
by: Jeremy | last post by:
How can one stop a browser from converting &amp; to & ? We have a textarea in our system wehre a user can type in some html code and have it saved to the database. When the data is retireved...
14
by: Arne | last post by:
A lot of Firefox users I know, says they have problems with validation where the ampersand sign has to be written as &amp; to be valid. I don't have Firefox my self and don't wont to install it only...
12
by: InvalidLastName | last post by:
We have been used XslTransform. .NET 1.1, for transform XML document, Dataset with xsl to HTML. Some of these html contents contain javascript and links. For example: // javascript if (a &gt; b)...
7
by: John Nagle | last post by:
I've been parsing existing HTML with BeautifulSoup, and occasionally hit content which has something like "Design & Advertising", that is, an "&" instead of an "&amp;". Is there some way I can get...
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...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
0
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...
0
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,...

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.