以下のリファレンスライブラリは、XPath 2.0、XQuery 1.0、およびXSLT 2.0に必要な関数を規定しています。 関数リファレンス
以下のリファレンスライブラリは、XPath 2.0、XQuery 1.0、およびXSLT 2.0に必要な関数を規定しています。 関数リファレンス
3. XPathXML や HTML の任意の位置を取得するための式XPathエンジンがあれば、 XPathを指定して HTML 上の値を簡単に持ってこれる 4. XPath<?php$url = 'http://www.nicovideo.jp/';libxml_use_internal_errors(true);$doc = new DOMDocument();$doc->loadHTML(file_get_contents($url));libxml_clear_errors();$xpath = new DOMXPath($doc);foreach ($xpath->query('//a') as $node) { echo $node->textContent . "";}
6 月のことになりますが、Kanasan.JS JavaScript 第 5 版読書会 #10 にて XPath に関する発表を行いました。内容は基本的な XPath の解説です。 発表資料: Excellent XPath Expressions (図、注釈付き) 図の元データ (OpenDocument Graphics 形式) 本番では図の準備が間に合わずホワイトボードに描きながら発表したのですが、逐次挙がる質問に対してもすぐ描き直して対応できたので、かえって理解を深めるのに役立ったのではないかと思います。資料中の注釈は口頭で説明したことなどを書き起こしたものです。 タイトルに excellent と入っていますが何か特に素晴しいということはなく、単に頭韻を踏みたかっただけです。(しかし excellent と expression では ex の発音が違うので踏めてないという……)
2010/06/05(土) に開かれた Kanasan.JS JavaScript第5版読書会#10 に参加した。 読んだところ 今回の範囲は P529 から P559。 XML の操作に関するところを読んだ。 JavaScript から新しい XML ドキュメントを作る方法とか、データアイランドとか、XSLT とか書いてあった。はっきり言ってあんまり使わないので、そんなものもあるのか、ぐらいに思っておけばいいんじゃないのかな。 XPath そして今回の目玉、nanto_vi さんによる XPath 解説。すごく楽しみにしてたので、期待が高まる。 で、発表してもらったんだけど、XPath を体系的に解説してもらった。こんなにまとまった話聞いたのは初めてで、めちゃ勉強になった。 そのときのお話と、あとから自分で調べたことのまとめ。 2010/09/29 追記 その時の発表資料が公開されました
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く