I am using an SQL query to extract web statistics from my website. This is done with the MySQL comand line tool and outputted as a HTML table.
The table is currently formatted like this:
<TABLE>
<TR><TH>Keyword</TH><TH>Date</TH><TH>IP/WHOIS</TH></TR>
<TR><TD>random phrase</TD><TD>2010-10-11</TD><TD>1.2.3.4</TD></TR>
</TABLE>
The table is then refined with a VBS script and mailed to specified recpients with another VBS script.
What I would like to do is include some sort of script that takes the IP address and makes a WHOIS lookup and returns the value contained in the "descr" field. The value could go into the same cell as the IP or a completely new column. The script should be able to execute via my "run.bat" file which is connected to the task scheduler. The script doesn't necessarily have to be VBS, but needs to be able to run via the batch file.