#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2002
    Posts
    2
    Rep Power
    0

    problem with parsing xml


    ok, i've got a small problem with my cms. i'm generating code out off a database (last x news/articles). following the xml-output. the problem is, that as soon as i'll open the file in ie or ns, the browser tells me that the file can't be parsed because of some missing data. but where's my mistake?

    Code:
    <?xml version="1.0"?><rdf:RDF
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
    xmlns="http://my.netscape.com/rdf/simple/0.9/">
    
    <channel>
    	<title>Contentpapst - Webnews</title>
    	<link>http://www.contentpapst.de</link>
    	<description>...</description>
    	<language>de</language>
    	<copyright>Copyright 2002, sandoba.de medien agentur</copyright>
    	<email>contact@sandoba.de</email>
    </channel>
    
    <item>
    	<title>es ist bald wieder weihnachten!</title>
    	<link>http://www.testurl.de/modules_news....e=detail&sid=45</link>
    	<description>...</description>
    </item>
    
    </rdf:RDF>
    Thank you for your help!!!
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2002
    Location
    new york
    Posts
    84
    Rep Power
    13
    have you tried including a DTD or Schema??
  4. #3
  5. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2002
    Posts
    2
    Rep Power
    0
    sorry, don't know what you mean with dtd. can you please explain it short'n'simple?
  6. #4
  7. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2002
    Location
    new york
    Posts
    84
    Rep Power
    13
    Document Type Definition...

    Basically, it defines the structure of your XML document. It tells the XML parser exactly which elements and attributes are allowed in your document and in what order...

    Here's an introduction:
    http://www.devshed.com/Server_Side/X...ign/page1.html

    Schemas accomplish the same task, but are slightly friendlier.

    Here's an introduction on that:
    http://www.devshed.com/Server_Side/X...ema/page1.html


    Check it out, if it doesn't solve your problem, it's still important to know.



    ===============
    justin->dago
    ===============

IMN logo majestic logo threadwatch logo seochat tools logo