php - How to get path to curent node with simplexml? -
i need path node in simplexml oject? domdocument->getnodepath()
foreach ($xml->xpath('.//tag-defs') $tagdef) { $path = $tagdef->*getnodepath()* //i need reciev path "/*/*[3]/*[1]" }
p.s. can't use domdocument!
Comments
Post a Comment