Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'I prefer to use curl over lynx' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
I prefer to use curl over lynx
Authored by: xargs on Jul 13, '10 10:21:28PM

A handy script, thanks!

I've adapted your script to use curl rather than lynx and removed the need to handle a temp file:

curl -s "http://www.geoiptool.com/en/?IP=${IP}" | 
textutil -stdin -format html -stdout -convert txt | 
sed -n "/Host Name/,/Postal code/p"

(This script requires the variable IP to be set)



[ Reply to This | # ]