Skip to main content
DevTools24

XPath 테스터

XML 문서에 대해 XPath 표현식을 테스트합니다. 실시간 결과로 데이터를 쿼리, 필터링 및 추출합니다.

No results. Enter an XPath and click Evaluate.

XPath Quick Reference:

//tag - Select all matching tags

/root/child - Absolute path

[@attr='value'] - Filter by attribute

[position] - Select by position (1-indexed)

/text() - Get text content

/* - Select all children

XPath Tester - 기술 세부 정보

XPath (XML Path Language) is used to navigate and select nodes in XML documents. It's essential for web scraping, XSLT transformations, and XML data processing. XPath expressions can select elements, attributes, and text nodes using path-like syntax.

명령줄 대안

# XPath in Python (lxml)\nfrom lxml import etree\ntree = etree.parse('file.xml')\nresults = tree.xpath('//book/title')\n\n# XPath in JavaScript\ndocument.evaluate('//div[@class]', document)