473,473 Members | 1,482 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

very easy beginner question(s)

1 New Member
hi all,
I just started to poke the xml and related concepts. What is not clear to me is the following:

I have an xml file called person.xml and since it is so short and simple I just posted it below:

<?xml version="1.0"?>
<?xml-stylesheet type="text/xml" href="C:\Documents and Settings\My Documents\XML\minimal.xsl"?>
<people>
<person born="1912" died="1954">
<name>
<first_name>Alan</first_name>
<last_name>Turing</last_name>
</name>
<profession>computer scientist</profession>
<profession>mathematician</profession>
<profession>cryptographer</profession>
</person>

<person born="1918" died="1988">
<name>
<first_name>Richard</first_name>
<middle_initial>M</middle_initial>
<last_name>Feynman</last_name>
</name>
<profession>physicist</profession>
<hobby>Playing the bongos</hobby>
</person>
</people>

At the same time, I have an empty stylesheet, the minimal.xsl posted below as well:

<?xml version="1.0"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
</xsl:stylesheet>

My question is: why do I get the xml file back whenever I open the person.xml with IE6 on an XP box with SP2.
If I open the same person.xml with Firefox 2.0.0.14 I get the element values in a string with no paragraph breaks just as seen below:
Alan Turing computer scientist mathematician cryptographer Richard M Feynman physicist Playing the bongos.

Now, if I do a CTRL+a in the Firefox browser and do a Ctrl+V here below, this is what I get - which is the thing the author of the book where I got this sample said it will happen.



Alan
Turing

computer scientist
mathematician
cryptographer




Richard
M
Feynman

physicist
Playing the bongos

Why is it not working with IE6 and why the exotic behavior of Firefox?

Thanks a bunch,
kowlasky
Jul 3 '08 #1
2 1505
gpraghuram
1,275 Recognized Expert Top Contributor
The XML parsers used by both the browsers are totally different and thats why the difference is...
I am dobtful gerading the way you have gived the XSL path in the xml file...


Raghu
Jul 4 '08 #2
jkmyoung
2,057 Recognized Expert Top Contributor
HTML processors automatically remove newlines; they treat them as just space. You would need a <br/> tag in order to have a newline.

Since you copied and pasted, you copied the newlines as well, but they render differently as text, then as HTML.
Jul 4 '08 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Todd_Calhoun | last post by:
I'm trying to generate a random number, and then concetate it to a word to create a password. I get the number and assign it to a variable: +++++++++++++++++++++++++++++ word = "dog" ...
11
by: Svens | last post by:
Hey everyone! I'm a math student working on a short script involving logs. I have a function on my scientific calculator, and was wondering if there was a similar funtion in python. For example:...
9
by: Tom | last post by:
Hey all, I've been planning to get myself started with DocBook for quite some time now, so when I unexpectedly encountered a task for which DocBook might actually be very useful, I thought I'd...
2
by: Alex | last post by:
Hello I am interested learn more about .NET but am uncertain of exactly what niche it fills in the world of programming. (The more I read the more I am confused). What I am looking for is the...
4
by: IS | last post by:
At the recommendation of several people in this newsgroup I have downloaded two or three Compilers. One is the Beta version of Microsoft's Visual C++ 2005. I have entered a complete beginner code...
4
by: Mason Barge | last post by:
I'm learning how to build a website. So far I've gotten pretty good with HTML, CSS, and Paint Shop Pro, and I'm currenly learning the basics of Javascript. I'm hoping, eventually, to build and...
2
by: cjl | last post by:
PHPers: I am a total beginner, so please excuse my very simple question. I have been playing with PHP on Windows XP, and mostly using Notepad2 (http://www.flos-freeware.ch/notepad2.html) for...
13
by: Jack B | last post by:
I'm using Access 2002 to create a database for a small opera company that my wife is involved in, and I'm more than a bit rusty because I haven't created a new Access database since about 1999. ...
4
by: a | last post by:
Dear all vb.net developer I want to know the time I need to master vb.net? I'm beginner
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
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
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,...
0
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...
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,...
1
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...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
muto222
php
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.