Solved

screen scraping from parent screen in asp

Posted on 2010-11-30
5
281 Views
Last Modified: 2012-05-10
I have a page that is contained in a frame.  My page is asp, the frame is generated by a different site on a different server.  

If I could tell if the frame contained a certain string, that would help me determine what my page needs to do.  Is there a way to see if the 'parent' frame contains a certain string?
0
Comment
Question by:d2fox
  • 2
5 Comments
 
LVL 18

Expert Comment

by:ChetOS82
ID: 34242416
Since your parent is on a different domain than your page, this is not possible.  Cross-domain scripting security prevents you from accessing the parent page's "internals".  You will get an "access denied" error.
0
 

Author Comment

by:d2fox
ID: 34242735
Well, I was hoping I could 'read' the text, e.g. what I'm referring to is actually displayed on the parent frame.  Can't I get the parent html somehow and look for the text that I'm interested in?  I think I've done this on my own page, just not on a parent page.
0
 
LVL 18

Accepted Solution

by:
ChetOS82 earned 500 total points
ID: 34242810
No, you cannot access the parent page's html from the child (unless they are both on the same domain).

You can try and see what happens.  Use window.parent.document to access the parent page.  You could try something like alert(window.parent.document.getElementsByTagName('html')[0].innerHTML);
0
 
LVL 29

Expert Comment

by:Kumaraswamy R
ID: 34429114
This question has been classified as abandoned and is being closed as part of the Cleanup Program.  See my comment at the end of the question for more details.
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This is pretty cool.  The purpose of this VB Script is to help you document where JAR (Java ARchive) files and specifically java class files are located so that you can address issues seen with a client or that you can speak intelligently with a dev…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

679 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question