djekl
9/4/2012 - 8:44 PM

Simple Tunlr.net YQL Data Table

Simple Tunlr.net YQL Data Table

<?xml version="1.0" encoding="UTF-8" ?>
<table xmlns="http://query.yahooapis.com/v1/schema/table.xsd">
    <meta>
        <description>Retrieves the IP adddresses for tunlr.net's DNS servers</description>
        <author>Anthony Sterling</author>
    </meta>
    <bindings>
        <select produces="JSON">
        <execute><![CDATA[
            var results = y.query("select content from html where url=\"http://tunlr.net/get-started/\" and xpath='//span[@style = \"font-size: xx-large;\"]'").results.*;
            var addresses = [];
            for each (var address in results) addresses.push(address.toString());
            response.object = {ip: addresses};
        ]]></execute>
        </select>
    </bindings>
</table>