Click here to Skip to main content
15,897,891 members
Please Sign up or sign in to vote.
3.00/5 (3 votes)
See more:
why we use XML will any1 tell me purpose need gv me some links plz xcpt wikipedia

Edit:
i want to ask why there is a need of xml if html is thr
Posted
Updated 16-Oct-11 7:36am
v2
Comments
Sander Rossel 16-Oct-11 13:37pm    
Edited your question. Deleted the answer to your own question and put the question there in your original post.

Wikipedia has a fine article on XML. I suggest you read it even though your teacher does not allow you to use it... Otherwise use GOOGLE![^].
The really short version? It's a standard that everyone knows.
 
Share this answer
 
Comments
Simon Bang Terkildsen 16-Oct-11 13:35pm    
Gotta keep in mind Google's up-time sucks, it's only about 5% :P
Sander Rossel 16-Oct-11 13:42pm    
Perhaps stupid questions make it crash... :p
Not referring to this one particulary. Question makes a lot more sense now that the OP has edited it.
Sergey Alexandrovich Kryukov 16-Oct-11 22:57pm    
Ha-ha, good point. However I think, yes, this question would contribute to the crash very well :-) -- please see my comment to the answer by Mehdi.
I would say, the second line of your answer is quite redundant, looks like you feel a need to excuse for XML existence :-). It's some people have such psychology to ask question the way putting anyone trying to answer in cumbersome position; such behavior should not be encouraged.
Nevertheless I voted 5 for the answer.
--SA
Sergey Alexandrovich Kryukov 16-Oct-11 23:10pm    
After all, I decided to add my own answer to all this (and especially your answer), please take a look.
--SA
Sander Rossel 17-Oct-11 1:54am    
Mind you that when I gave my answer the OP had only asked about what XML was on not yet about the difference with HTML. So my answer might seem a bit incomplete ;)
When I noticed the OP had asked about HTML Mehdi had already given a good answer :)
 
Share this answer
 
Comments
Simon Bang Terkildsen 16-Oct-11 13:35pm    
Good one
Abhinav S 16-Oct-11 13:38pm    
Thank you.
Sander Rossel 16-Oct-11 13:39pm    
Nice link :)
Sergey Alexandrovich Kryukov 16-Oct-11 22:47pm    
Makes perfect sense, a 5. See also my comment to the answer by Mehdi.
--SA
Sergey Alexandrovich Kryukov 16-Oct-11 23:10pm    
After all, I decided to add my own answer to all this, please take a look.
--SA
XML came about in the era of HTML wars where everyone was defining their own tags, so the standards comitee gave up and said here you go now you can define your own schema and tags to your hearts content.

After the dust settled on the browser wars, people saw that XML makes a lot of sense for data transfer between different systems and servers.

So XML and xsl lost favour as HTML generators and exploded as human and machine readable data transfer format.
 
Share this answer
 
Comments
Simon Bang Terkildsen 16-Oct-11 13:37pm    
Good history lesson :)
Mehdi Gholam 16-Oct-11 13:40pm    
My take on it anyway :)
Sander Rossel 16-Oct-11 13:38pm    
My 5!
Sergey Alexandrovich Kryukov 16-Oct-11 22:46pm    
My 5. One good feature of this answer is that you did not put yourself in cumbersome position trying to literally answer totally pointless question by OP. Same thing as with questions: "Why there is a need in computer languages if machine code is there?", "Why there is a need in solar panels if petroleum is there?", etc.
--SA
Mehdi Gholam 16-Oct-11 23:32pm    
Another good one is: why are we here answering questions, when google exists!
Very basically: this is because HTML sucks. It's its "relaxed" HTML syntax and a lot of uncertainties in interpretation of tags created the situation when HTML Web pages are rendered with so many difference by any pair of different layout engines, see http://en.wikipedia.org/wiki/Comparison_of_web_browser_engines[^].

So, it was natural that people created the language which would suck much less and gets more universal application. When I say "much less" I mean it: it still sucks. I feel it well because years ago when good parsers were not yet available I happened to develop some XML processing and knew a good number of inconsistencies, especially in the pretty lousy text of the standard. This is well illustrated by the Annotated XML Specification by Tim Bray, see http://www.xml.com/axml/testaxml.htm[^].

—SA
 
Share this answer
 
v3
Comments
Abhinav S 17-Oct-11 0:22am    
Sure. My 5.
Sergey Alexandrovich Kryukov 17-Oct-11 0:51am    
Thank you, Abhinav.
--SA
Mehdi Gholam 17-Oct-11 1:10am    
I have gone completely off XML in favour of JSON. 5!
Sergey Alexandrovich Kryukov 17-Oct-11 1:22am    
Interesting. I have no certain opinion in comparing them. Thank you, Mehdi.
--SA
Sander Rossel 17-Oct-11 1:52am    
HTML sucks! Nice answer, my 5 ;)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900