Re: [xml] xmlNewDocProp() doesn't appear to do anything...



Call me crazy, but, it seems like xmlNewDocProp() is broken.  I've
resorted to setting a property on the root node, but I'd think that
xmlNewDocProp() would behave the same... does it not?

  No. xmlNewDocProp() create a property, but does not attach it to
an element, it's created anyway, and it's the user's responsability
to attach it to an element.  But it has to be created in the context
of a document.

Alright... what's the purpose of this then?  Is this any different
from adding a property to the root element of a document?  Is a
document property struct any different than a normal attribute?  I saw
this, added it to Ruby's libxml interface... but never saw the purpose
of this and am now just flat out confused as to its purpose.  -sc

-- 
Sean Chittenden



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]