473,372 Members | 1,034 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,372 software developers and data experts.

very easy beginner question(s)

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"?>
<person born="1912" died="1954">
<profession>computer scientist</profession>

<person born="1918" died="1988">
<hobby>Playing the bongos</hobby>

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">

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 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.


computer scientist


Playing the bongos

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

Thanks a bunch,
Jul 3 '08 #1
2 1501
1,275 Expert 1GB
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...

Jul 4 '08 #2
2,057 Expert 2GB
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

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" ...
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:...
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...
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...
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...
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...
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...
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. ...
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
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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
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...
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...
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...

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.