this code works brillianly - test it out by replacing url with google on line 36 of web.js file