下面的代码, 不会报错, 但是没有任何输出, 求高手指点, 感谢!- $xml = [xml]@"
- <?xml version="1.0" encoding="utf-8" ?>
- <root>
- <users job="salas">
- <user>
- <name>Joe</name>
- <age>17</age>
- </user>
- <user>
- <name>Kate</name>
- <age>12</age>
- </user>
- </users>
- <users job="developer">
- <user>
- <name>David</name>
- <age>23</age>
- </user>
- <user>
- <name>Eath</name>
- <age>54</age>
- </user>
- </users>
- </root>
- "@
- $users = $xml.SelectNodes("users")
-
- $users
复制代码
|