Community Documentation

Introduction

Last updated January 23, 2013. Created by mitchell on January 30, 2011.
Edited by Soul88, j9, shamio, Vacilando. Log in to edit this page.

Feeds XPath Parser implements XPath 1.0 in Feeds, allowing the selection of nodes from an XML document. The XPath language is based on a tree representation of the XML document, and provides the ability to navigate around the tree, selecting nodes by a variety of criteria. In addition, XPath may be used to compute values (strings, numbers, or boolean values) from the content of an XML document.

XPath example

To begin learning XPath, start with this fine XPath Tutorial, and refer to the XPath Syntax Reference.

For more general information on XPath, refer to the Wikipedia XPath page or the detailed W3C spec.

It should also be mentioned that if you want to import different "projects" to different nodes from the example above - you should set "Context" from "XPath Parser Settings" to "/wikimedia/projects/project". And then add something like "editions/*[2]" for the second value of the "edition" field.

AttachmentSize
XPath_example.svg_.png87.91 KB

About this page

Drupal version
Drupal 6.x, Drupal 7.x

Site Building Guide

Drupal’s online documentation is © 2000-2013 by the individual contributors and can be used in accordance with the Creative Commons License, Attribution-ShareAlike 2.0. PHP code is distributed under the GNU General Public License. Comments on documentation pages are used to improve content and then deleted.