• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Mock Exam Question

 
Harsha Jay
Ranch Hand
Posts: 177
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
 
Hari Vignesh Padmanaban
Ranch Hand
Posts: 578
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi harsha,
The document will work fine as it does not have the DTD declaration and also xml:space is already a pre defined variable in the XML vocabulary.
And logically b cannot be the answer, if you include a DTD with the file. In that case option 'a' is right. YOu will have to define an attribute called "xml:space" !!!
So lets see the DTD
<!ELEMENT root EMPTY>
<!ATTLIST root xml:space REQUIRED "preserve">
The otehr value that xml lang can take is "default".
Hope this helps !!! ALSO DTD's do not go along with Namespaces !!
hari
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic