Page 1 of 1

How to get webpage data

Posted: Wed Sep 12, 2018 9:14 pm
by fredjoans
Hello,

Hoping someone can help here. I can retrieve webpage data by using this format:

put url ("https://www. genericpage .com/generic_search.php?valid=y&active=y&Search=Search") into tReturnedData

But tReturnedData has what appears to be the page source html code.

What I would like to ask is how do I get the text data that would be displayed on the webpage.. not the page source, but the data displayed in the browser, I guess more like http GET /generic_search.php?valid=y&active=y&Search=Search.

-fj

Re: How to get webpage data

Posted: Wed Sep 12, 2018 9:27 pm
by Klaus
Hi Fred,

welcome to the forum!

There is a trick to extract the pure text from a HMTL page:

Code: Select all

...
lock screen

## Load HTML source into a field:
put url("https://www.genericpage.com/generic_search.php?valid=y&active=y&Search=Search") into fld 1

## Then (try) to see what the HTML source will display:
set the htmltext of fld 1 to the text of fld 1
...
LC only supports a little part of HTML code however, CSS is NOT supported unfortunately,
so this may not fit your needs, but give it a try. :D

Best

Klaus

Re: How to get webpage data

Posted: Wed Sep 12, 2018 9:49 pm
by fredjoans
Klaus,

That will work! Very helpful, thanks a bunch for that bit of info. Very useful indeed.

-fj