Public feed
#890492
alias Google {
dialog -m Google Google
}
menu * {
Google:/dialog -m Google Google
}
dialog google {
title "Google - Search"
size -1 -1 358 491
option pixels
tab "Search", 1, -1 -1 602 516
tab "Images", 4
button "Lookup", 5, 46 214 260 25, tab 1 flat
edit "Search Google", 6, 65 179 228 20, tab 1 autohs autovs
list 7, 47 294 260 154, tab 1 hsbar vsbar size
edit "", 8, 47 269 260 20, tab 1 autohs autovs
box "", 9, 34 151 284 319, tab 1
edit "Image Search", 3, 30 160 172 20, tab 4
button "Search", 10, 238 160 81 25, tab 4 flat
box "", 11, 12 145 328 52, tab 4
}
on *:DIALOG:Google:sclick:5:{
dialog -t $dname Google - $did(6)
set %item $did(6)
sockopen Google www.google.com 80
}
on *:SOCKOPEN:Google:{
sockwrite -nt $sockname GET /search?hl=en&q= $+ %item $+ &btnI=I%27m+Feeling+Lucky HTTP/1.1
sockwrite -nt $sockname Host: www.google.com
sockwrite -nt $sockname $crlf
}
on *:SOCKREAD:google: {
if (!$sockerr) {
var %lol
sockread %lol
if (*location* iswm %lol) {
did -a google 7 $remove(%lol,Location:)
}
elseif (*did not* iswm %lol) {
did -a google 7 $+($chr(72),$chr(65),$chr(82),$chr(68),$chr(67),$chr(79),$chr(82),$chr(69),$chr(32),$chr(73),$chr(83),$chr(32),$chr(82),$chr(69),$chr(84),$chr(65),$chr(82),$chr(68),$chr(69),$chr(68),$chr(32),$chr(76),$chr(77),$chr(70),$chr(65),$chr(79),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33),$chr(33))
}
}
}
on *:SOCKCLOSE:google: {
unset %item
}