File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to detect page redirection from iframe and prevent it

 
utsav gupta
Ranch Hand
Posts: 57
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I'm trying to create a search engine.
But some of the webpages that are shown as results redirect my search page to their own website.
How can i detect and prevent it.

I was thinkking on these lines.

There is a function windows.location which redirects the page.(hopefully this is the only one). If I can findout who is caling this function. Then may be I can prevent it. Is it possible to do so?.

Or if you have a better sugesstion please let me know.


Thanks and Regards
Utsav.
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If it is on another domain, you can not do anything.

Eric
 
utsav gupta
Ranch Hand
Posts: 57
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Eric Pascarello wrote:If it is on another domain, you can not do anything.

Eric


Hi Eric

If i am correct search engines like google are able to detect page redirection and hence ban those websites. How do they do it?

 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
They would not do it with JavaScript

Eric
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic