how to disable google image search popup box

by 3 replies
5
I know you can tweak your browser to do this, but is there code you can put on your website?

When someone clicks on a google image search thumbnail, I'd like it to go directly to my web page rather than display the popup, forcing a second click to get in.

I have seen image thumbnails do that before, but of course I can't find them now!
#programming #box #disable #google #image #popup #search
  • not possible
    the search results are hosted on google servers, and you cannot affect any change on the google servers, only on your own server.
    • [1] reply
    • Actually it is possible and it's actually very easy. I use it on everyone of my sites. When a user clicks on the image thumbnail, the thumbnail is simply displayed in an iframe. With javascript you can check for frames and break out of them.

      Here's the code:

      Code:
      <script type="text/javascript"> 
      function breakout_of_frame() {  
       if (top.location != location) {   
        top.location.href = document.location.href ;   
      } 
      } 
      </script> 
       </head> 
      <body onload="breakout_of_frame()">
      • [ 1 ] Thanks
      • [1] reply

Next Topics on Trending Feed

  • 5

    I know you can tweak your browser to do this, but is there code you can put on your website? When someone clicks on a google image search thumbnail, I'd like it to go directly to my web page rather than display the popup, forcing a second click to get in.