How much interaction is possible between Rev and a revBrowser instance?
For example, simply to select some text, it is possible to use libBrowserSet "selected", theText - but what if you wanted to select all of the text on the browser window? (can you set "theText" to use wildcards?) Or can you select the html source code of the browser window?
For other features, is there any way of addressing the browser object in the same way you can address a field on a card, say?
interaction with a revBrowser instance
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Hi SparkOut,
It is possible to write a script that removes the headers and scripts from the HTML code and the tags from the body. Eventually, the body text should be remaining. You might try to select the text using the cleaned up html source as string.
Why would you want to select the HTML source code? You can get the htmlText of the browser instance using revBrowserGet.
There are a few messages possible for interaction with a browser instance, but they are all specific to the browser object.
I hope this helps (but I doubt it).
Best regards,
Mark
It is possible to write a script that removes the headers and scripts from the HTML code and the tags from the body. Eventually, the body text should be remaining. You might try to select the text using the cleaned up html source as string.
Why would you want to select the HTML source code? You can get the htmlText of the browser instance using revBrowserGet.
There are a few messages possible for interaction with a browser instance, but they are all specific to the browser object.
I hope this helps (but I doubt it).
Best regards,
Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode
No Mark, it's helped enormously! Thanks! I can't believe I've missed that, I've been scouring the revBrowserGet function for some way of doing that, and not seen the wood for the trees. I've been trying all sorts of combinations of things (see my post http://forums.runrev.com/phpBB2/viewtop ... 0170#10170 ) to get around the problem of not being able to POST data to log in and follow the server redirect to receive cookies. Making a browser inside the app works well enough to log in and see the data, but I was struggling to get the data from the browser object to be able to use it.
Of course if there's a way of picking up the cookies by making a POST follow the redirect from the server, that'd be even better.
Of course if there's a way of picking up the cookies by making a POST follow the redirect from the server, that'd be even better.
Interestingly (not that it's a problem in this case, as long as it's consistent) the htmlText that's returned by revBrowserGet has had almost all the quotes stripped from the source code. So <SPAN id="lblReportDate"> has been returned as <SPAN id=lblReportDate> - any ideas why that should be the case?
The first line <HTML xmlns="http://www.w3.org/1999/xhtml"> declaration is the only place where quotes have been kept.
The first line <HTML xmlns="http://www.w3.org/1999/xhtml"> declaration is the only place where quotes have been kept.