OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

 


 

   Re: Undeclared namespace

[ Lists Home | Date Index | Thread Index ]
  • From: "Anand Raman" <anandram@wipsys.soft.net>
  • Date: Mon, 01 Nov 1999 14:51:11 +0530

Hi guys
Sorry to have been out of this discussion for some time , but i we were having holidays here
..
Thomas the code which u wrote works in my IE too. But that was not my problem .. I had
duplicate elements in the DTD and i was trying to use namespaces to overcome this. However IE
required a explicit namespace attribute definition in the DTD wherever i used exp: .Anyway the
problem was solved after incoporatiing this.

I am attaching the relevant portions of the xml and DTD file here .
The problem was occuring when i had not used line number 8 and 12 respectively in the DTD ..
After incorporating these lines IE 5 is displaying the XML file

Thanx a lot for all the help
Bye
Anand Raman


"Thomas B. Passin" wrote:

> From: Mark Birbeck <Mark.Birbeck@iedigital.net>
>
> > Thomas B. Passin wrote:
> > > My version of IE5 does not need to have the namespace
> > > declared as a #FIXED attribute
> >
> > Please send me a copy of it, or tell me where you downloaded it from.
> >
> > Just joking, but I disagree, Thomas. This was discussed a while back in
> > relation to XHTML, when I seriously fell out of love with Microsoft.
>
> Probably before I joined the list.
>
> Just to be complete even though you said you were joking, I just rechecked
> using my copy of IE5.  The XML with DTD works even though there is no
> namespace attribute declared in the DTD.  My exact version of IE5 is
>
>     5.00.2614.3500, 128 bit
>
>     update versions q231452, q231450
>
> The actual xml document I tested is the following, based on Anand Raman's
> original mailing:
>
> =========================================================================
> DOCTYPE experience[
> <!ELEMENT experience (project+)>
> <!ELEMENT project
> (title,employer?,client?,duration?,team?,position?,description?,contribution
> ?)>
> ]>
>
> <experience xmlns:exp="http://www.angelfire.com/ar/diduknow/experience">
>  <project>
>    <exp:title>Management Information Systems</exp:title>
>    <employer>Infotech ESD</employer>
>    <client>Finance Department</client>
>    <exp:duration>till date</exp:duration>
>   </project>
> </experience>
> ==========================================================================
>
> When I say that "it works", I mean that IE5 displays the document text and
> does not give any error messages.
>
> > If you convert HTML to nice neat XHTML and then try to use a reference
> > to the DTDs supplied by W3C you get errors. The W3C DTDs do not define
> > the namespace attribute as fixed, and MS in their wisdom have said you
> > must. No-one has explained why, and there is little justification for
>
> The W3C namespace recommendation does say that if you use a DTD you have to
> declare the namespace.  It also says that the namespace declaration can be
> established by the default value for the (namespace) attribute.  This
> implies that you may optionally declare its value in the DTD (#FIXED would
> also be optional), and then you would not have to specify the namespace when
> you actually write an element.  But my version of IE5 insists on needing the
> namespace declaration in the element event if the DTD declares it as #FIXED!
> Also, the Recommendation says that element and attribute name declared in
> the DTD must be qualified.  Again, my copy of IE5 differs, since it would
> not allow the qualification in the DTD.
>
> Christopher R. Maden is right when he said that the above example for IE5
> would not validate against the Recommendations, but it does work with my
> IE5.
>
> So I don't bother using IE5's xml or xsl capabilities.  It's not worth it
> even for use as a learning tool, you have to unlearn too much.
>
> > it, so the only solution is to remove the DTD reference - and of course
> > you no longer technically have valid XHTML!!!!!!
> >
> > Damn. I was doing so well. My therapist is going to be very
> > disappointed.
> >
> > Mark
> >
>
> xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@ic.ac.uk
> Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/ and on CD-ROM/ISBN 981-02-3594-1
> To unsubscribe, mailto:majordomo@ic.ac.uk the following message;
> unsubscribe xml-dev
> To subscribe to the digests, mailto:majordomo@ic.ac.uk the following message;
> subscribe xml-dev-digest
> List coordinator, Henry Rzepa (mailto:rzepa@ic.ac.uk)
<!ELEMENT resume (experience,education,training)>

<!ELEMENT experience (project+)>
<!ATTLIST experience xmlns:exp CDATA #FIXED "http://www.angelfire.com/ar/diduknow/experience">
<!ELEMENT project (exp:title,employer?,client?,exp:duration?,team?,position?,description?,contribution?)>
<!ATTLIST project id ID #IMPLIED>
<!ELEMENT exp:title (#PCDATA)>
<!ATTLIST exp:title xmlns:exp CDATA #FIXED "http://www.angelfire.com/ar/diduknow/experience">
<!ELEMENT employer (#PCDATA)>
<!ELEMENT client (#PCDATA)>
<!ELEMENT exp:duration (#PCDATA)>
<!ATTLIST exp:duration xmlns:exp CDATA #FIXED "http://www.angelfire.com/ar/diduknow/experience">
<!ELEMENT team (#PCDATA)>
<!ELEMENT position (#PCDATA)>
<!ELEMENT description (#PCDATA)>
<!ELEMENT contribution (list+)>
<!ELEMENT list (#PCDATA)>
<!ATTLIST list id ID #IMPLIED>

<!ELEMENT education (degree+)>
<!ELEMENT degree (title,institute,year,percentage?,grade?)>
<!ELEMENT title (#PCDATA)>
<!ELEMENT institute  (#PCDATA)>
<!ELEMENT year   (#PCDATA)>
<!ELEMENT percentage  (#PCDATA)>
<!ELEMENT grade (#PCDATA)>
<!ATTLIST degree id ID #IMPLIED>

<!ELEMENT training (course+)>
<!ELEMENT course (tname,org,duration?)>
<!ELEMENT tname (#PCDATA)>
<!ELEMENT org (#PCDATA)>
<!ELEMENT duration (#PCDATA)>
<!ATTLIST course id ID #IMPLIED>
<?xml version="1.0" standalone="no"?>
<!DOCTYPE resume SYSTEM "dtdfile.dtd">   
<resume>

<experience xmlns:exp="http://www.angelfire.com/ar/diduknow/experience">
	<project>
		 <exp:title>Financial Accounting and Management Information Systems</exp:title>
		 <employer>Infotech </employer>
		 <client>Finance Department, </client>
		 <exp:duration>Dec 98 to till date</exp:duration>
		 <team>10 members </team>
		 <position> Team Member </position>
		 <description>	The Finance Department </description>
		 <contribution> 
		 	<list> Development and maintenance of MIS Reports.</list>
		 	<list> Reconciliation of all Bank Accounts .</list>
		 	<list> Generating Ad hoc reports</list>
		 	<list> Development of Alerts </list>
		 	<list> Importing of vendors</list>
		 	<list> Simple database administration </list>
		</contribution>
	</project>
</experience>

<education>
	<degree>
		<title>	Bachelor of Engineering </title>
		<institute> Motilal Nehru Regional Engineering College (Allahabad University) </institute>
		<year> 1994 - 1998</year>
		<percentage> 79.8 % </percentage>
		<grade/>
	</degree>
</education>

<training>
	<course>
		<tname>Oracle (SQL, PL/SQL) </tname>
		<org> Training Department Wipro - ESD</org>
		<duration/>
	</course>
</training>
</resume>




 

News | XML in Industry | Calendar | XML Registry
Marketplace | Resources | MyXML.org | Sponsors | Privacy Statement

Copyright 2001 XML.org. This site is hosted by OASIS