This is my current xpath query:
//node:Expr_Assign[subNode:var/node:Expr_Variable/subNode:Name/scalar:string='my_chinese_surname' and subNode:expr/node:Scalar_String/subNode:value/scalar:string='Qiu']
I'm trying to find it in this xml:
<?xml version="1.0" encoding="UTF-8"?>
<AST xmlns:node="http://nikic.github.com/PHPParser/XML/node" xmlns:subNode="http://nikic.github.com/PHPParser/XML/subNode" xmlns:attribute="http://nikic.github.com/PHPParser/XML/attribute" xmlns:scalar="http://nikic.github.com/PHPParser/XML/scalar">
<scalar:array>
<node:Expr_Assign>
<attribute:startLine>
<scalar:int>2</scalar:int>
</attribute:startLine>
<attribute:endLine>
<scalar:int>2</scalar:int>
</attribute:endLine>
<subNode:var>
<node:Expr_Variable>
<attribute:startLine>
<scalar:int>2</scalar:int>
</attribute:startLine>
<attribute:endLine>
<scalar:int>2</scalar:int>
</attribute:endLine>
<subNode:name>
<scalar:string>my_chinese_surname</scalar:string>
</subNode:name>
</node:Expr_Variable>
</subNode:var>
<subNode:expr>
<node:Scalar_String>
<attribute:startLine>
<scalar:int>2</scalar:int>
</attribute:startLine>
<attribute:endLine>
<scalar:int>2</scalar:int>
</attribute:endLine>
<subNode:value>
<scalar:string>Qiu</scalar:string>
</subNode:value>
</node:Scalar_String>
</subNode:expr>
</node:Expr_Assign>
</scalar:array>
</AST>
It's not currently working. Infact I can't even select the scalar:array.
What's wrong with the query?
I figured it was namespaces. But I can't register them, the urls are dead? http://nikic.github.com/PHPParser/XML/node this doesn't lead anywhere.