samudaya Posted August 21, 2008 Share Posted August 21, 2008 Hi, I have two problems regarding the xml reading in the php. How to read attribute values in tags <c r="A1" s="5" t="s"> <v>0</v> </c> I want to identify the values assigned to “t” in tag <c> as the string ‘s’. How to do this in php? What are the meaning of “:” separation inside the tag <table:table table:name="Sheet1" table:style-name="ta1" table:print="false"> <table:table-column table:style-name="co1" table:number-columns-repeated="4" table:default-cell-style-name="Default"/> <table:table-row table:style-name="ro1"> <table:table-cell office:value-type="string"> <text:p>A</text:p> </table:table-cell> </table:table-row> </table:table> I can’t understand the tag names. When I used the whole name it gives a error regarding the “:”. Is that whole name, or what are the tag names? Link to comment https://forums.phpfreaks.com/topic/120672-read-xml-in-php/ Share on other sites More sharing options...
Fadion Posted August 21, 2008 Share Posted August 21, 2008 The colon specifies a namespace for that element. You can read about xml namespaces here and here. For parsing the xml, i've used simplexml but not that i'm an expert in the field. Found these two (one, two) introduction articles to simplexml which should give you an insight of what and how can be achieved. Link to comment https://forums.phpfreaks.com/topic/120672-read-xml-in-php/#findComment-621848 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.