Skip to content

Google Suggests.

The coolest web tool I've seen in a while. Google Suggests works by suggesting some search results WHILE YOU ARE TYPING search keywords (without refreshing the page).

Thanks go to Chris Justus from Server Side Guy for pointing out the service and its internals.

The google code uses an XMLHttp object to make calls back to google, and executing the results… to fully understand the code, I need to see what google is sending back… BUT when I tried the url directly, I didn't get anything but a 404 back from google (it turns out I had mis-typed the generated url…)… I tried to have my browser go through a local proxy server, but it appears that the XMLHttp object doesn't use the browsers proxy when communicating (which means that this might not work if you're behind a proxy server… Can people confirm this??) … I would have fallen back on a packet sniffer to capture the data, but caught my mistake in the URL before reaching this point…

1) You can turn the browsers autocomplete off by adding autocomplete=”off” attribute to an input field… How did I not know this before…
2) The XMLHTTP / XMLHttpRequest object to communicate back with a server and get new info / instructions without refreshing the page … the new black of web development… go read everything you can about this…
3) How powerful the keypress handling can be with javascript… (capturing keyup/keydown and events and changing state for cursor key events, etc…)
4) You can highlight text in an input field using javascript…

I guess I will be spending some time with “XMLHttp”, definitely interesting.

Posted in Java.

2 Responses

Stay in touch with the conversation, subscribe to the RSS feed for comments on this post.

  1. the Warehouse Guy says

    XMLHTTP is an amazingly powerfull tool that has been in IE for years now. While I’m not sure when it was really finalized into Netscape/Mozilla, we built a complete warehouse management tool around it in late 2001.

    Using the XMLHttp object to make background calls to the inventory db, we were able to give the end user an experience that rivals a desktop application, without rolling a new install to every warehouse computer every time an update is made.

    The really amazing thing is that we were able to handle 13 warehouses and a completely wireless infrastructure from a single centrally located server, thereby saving literally millions of dollars in servers and software costs.

  2. Christian Kamel says

    Hey, you’re in Egypt!? I was about to enter the blog world and I never thought there could be another Egyptian doing this stuff :D
    I’m a fellow egyptian working in the same industry you are… except I’m less into open sourced stuff
    You know how rare it is to meet another egyptian on the net somewhere else than arabic and dating sites. that’s why it’s really good to see you, keep up the good work :)

Some HTML is OK

or, reply to this post via trackback.