FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » Problem creating XML file
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: Problem creating XML file [message #179567 is a reply to message #179565] Thu, 08 November 2012 00:50 Go to previous message
Michael Fesser is currently offline  Michael Fesser
Messages: 215
Registered: September 2010
Karma:
Senior Member
.oO(dandi(dot)box(at)gmail(dot)com)

> Why are you talking about to create an empty children?
>
> I need this:
>
> <docAzione>
> <documento nome="Prova1.txt" />
> <documento nome="Prova2.txt" />
> </docAzione>
>
> Why do you see "empty children"?

Because your <documento/> are empty children, they don't have any
content. 'nome' is an attribute, but the elements themselves are empty.

This is an empty element:

<foo/> or <foo></foo>

This is a non-empty element:

<foo>bar</foo>

So, for each row from your database, create an empty 'documento'
element, add a 'nome' attribute to it with the value from the DB and
then append the whole thing to the root 'docAzione' element.

Micha

--
http://mfesser.de/
Fotos | Blog | Flohmarkt
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: How awesome Virtual Sailor 7 is
Next Topic: Order of Echoed HTML Output
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Fri Nov 22 04:33:06 GMT 2024

Total time taken to generate the page: 0.05236 seconds