Jump to content


 


Register a free account to unlock additional features at BleepingComputer.com
Welcome to BleepingComputer, a free community where people like yourself come together to discuss and learn how to use their computers. Using the site is easy and fun. As a guest, you can browse and view the various discussions in the forums, but can not create a new topic or reply to an existing one unless you are logged in. Other benefits of registering an account are subscribing to topics and forums, creating a blog, and having no ads shown anywhere on the site.


Click here to Register a free account now! or read our Welcome Guide to learn how to use this site.

Photo

HTML and Iframe, how to scan the output


  • Please log in to reply
2 replies to this topic

#1 skorpio

skorpio

  • Members
  • 2 posts
  • OFFLINE
  •  
  • Local time:09:30 PM

Posted 09 May 2011 - 09:59 AM

I am using IE8 and have a program that outputs to an html page:

http://127.0.0.1/pmta/status (note there is no status.*), this is just text output


it displays a grid of names and numbers that i want to scan. actually it is one number that i want to scan, it is the value displayed in row "smtp" and column "rcpts" (see attached snapshot). when that value exceeds a preset limit, i want it to run an executable.

Grid Snapshot

im using iframe as seen below, how can i scan for this value?? would prefer the simplist solution...

<html>
<body style="text-align:center;">
<iframe src="http://127.0.0.1/status"
	name="pmtaiframe"
	longdesc="http://127.0.0.1/" 
	width="700px" 
	height="500px"
	frameborder="0"
	align="middle"
	style="text-align:center;">
<p>this browser does not support the iframe element, please use internet explorer</p>
</iframe>
</body>
<html>

Edited by skorpio, 09 May 2011 - 10:13 AM.


BC AdBot (Login to Remove)

 


#2 groovicus

groovicus

  • Security Colleague
  • 9,963 posts
  • OFFLINE
  •  
  • Gender:Male
  • Location:Centerville, SD
  • Local time:07:30 PM

Posted 10 May 2011 - 07:14 AM

There are any number of 'simple' solutions. Write your own page to load the frame and then use Javascript to search the HTML for the value that you want. Use PHP, Java, or any other number of languages to retrieve the raw HTML, then search through it to find the values that you want.

It is called 'screen-scraping'.

#3 skorpio

skorpio
  • Topic Starter

  • Members
  • 2 posts
  • OFFLINE
  •  
  • Local time:09:30 PM

Posted 10 May 2011 - 11:43 AM

Thanks groovicus, i have been on a screen scraping tutorial all day...found maybe one program that might work, waiting on tech support to see how to properly configure the rules..

however having said that, if i use the above code and put in my javascript statement, <script type="text/javascript">, where do i go next? in this case lets use javascript as i have some basic understanding...

can someone help out with the basic code to grab the output (it refreshes every 5 seconds), find the one cell that i want to monitor and return that value?

thanks




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users