求大神,菜鸟一枚,有关于xpath的,感激不尽!!
xml吧
全部回复
仅看楼主
level 1
chiuwingyannv 楼主
<?xml version="1.0"encoding="ISO-8859-1"?>
<bookstore>
<book category="COOKING">
<titlelang="en">Everyday Italian</title>
<author>Giada De Laurentiis</author>
<year>2005</year>
<price>30.00</price>
</book>
<book category="CHILDREN">
<titlelang="en">Harry Potter</title>
<author>JK. Rowling</author>
<year>2005</year>
<price>29.99</price>
</book>
<book category="WEB">
<titlelang="en">XQuery Kick Start</title>
<author>James McGovern</author>
<author>PerBothner</author>
<author>Kurt Cagle</author>
<author>James Linn</author>
<author>VaidyanathanNagarajan</author>
<year>2003</year>
<price>49.99</price>
</book>
<book category="WEB">
<titlelang="en">Learning XML</title>
<author>Erik T. Ray</author>
<year>2003</year>
<price>39.95</price>
</book>
</bookstore>
使用XPath路径查找以下内容
1)读取属性lang=”en”的元素的内容
2)读取XQuery Kick Start这本书的第一个author的内容
3)读取所有price大于35的book元素的title
这几题不会,求大神讲解,感激不尽![泪]
2016年12月06日 14点12分 1
level 1
chiuwingyannv 楼主

2016年12月06日 14点12分 2
1