Capturing EXTRACT data

Discussions and Tech Support related to website data extraction, screen scraping and data mining using iMacros.

Moderators: Community Moderators, iMacros Moderators

Forum rules
Before asking a question or reporting an issue:
1. Please review the list of FAQ's.
2. Use the Google search box (at the top of each forum page) to see if a similar problem or question has already been addressed. This will search the entire contents of the forums as well as the iMacros Wiki.
3. We can respond much faster to your posts if you include the following information:

CLICK HERE FOR IMPORTANT INFORMATION TO INCLUDE IN YOUR POST

Answering your own posts (e.g. attempting to "bump" your topic) drops your topic from the list of unanswered threads, so it may actually receive less views.

Capturing EXTRACT data

by Raisins on Thu May 25, 2017 10:36 am

iMacros Version V. 844
Browser Google Chrome versions is: 58.0.3029.110 (64-bit)
Operating System macOS Sierra V. 10.12.5
Included Demos work ok (all of them)

Also tried briefly on a Windows 10 system with Chrome with the same results. All demos worked.


Is there a way to put user-entered data into a variable?

I had been using PROMPT to capture user input data as a variable...

PROMPT "Please enter text:" !VAR1

Unfortunately, PROMPT no longer works with the latest Chrome update.

I've come up with the following workaround that EXTRACTs the user input from an html form I created. But I can't pass that data along because EXTRACT is not a variable and IEXTRACT does not work within a TAG. I've spent a lot of time with this and I haven't found a way to do this. Is there a way to load TAG EXTRACT'd data into a variable?

This is what I am trying to do...

URL GOTO=C:\Users\username\Desktop\FormTest.html
TAG POS=1 TYPE=INPUT:TEXT FORM=NAME:form1 ATTR=NAME:abc EXTRACT=TXT

SET !VAR1 {{!EXTRACT}}

TAB OPEN NEW
TAB T=2
URL GOTO=http://www.forvo.com/word/{{!VAR1}}/#ar

No luck with this, even though I found some demo samples that said it should work.

Any suggestions would be appreciated. Thank you.
Raisins
 
Posts: 3
Joined: Thu May 25, 2017 10:25 am

Re: Capturing EXTRACT data

by iimfun on Fri May 26, 2017 11:18 pm

Raisins wrote:I had been using PROMPT to capture user input data as a variable...

PROMPT "Please enter text:" !VAR1

Unfortunately, PROMPT no longer works with the latest Chrome update.

I encountered the same problem. Here is my workaround for that

Code: Select all
SET !VAR1 EVAL("prompt('Please enter text:');")
PROMPT {{!VAR1}}
iimfun
 
Posts: 209
Joined: Tue Jul 19, 2016 6:06 am

Re: Capturing EXTRACT data - CLOSED

by Raisins on Sat May 27, 2017 5:27 am

Thank you. This works
Raisins
 
Posts: 3
Joined: Thu May 25, 2017 10:25 am

Re: Capturing EXTRACT data

by chivracq on Sat May 27, 2017 6:43 am

Raisins wrote:
Code: Select all
iMacros Version V. 844
Browser Google Chrome versions is: 58.0.3029.110 (64-bit)
Operating System macOS Sierra V. 10.12.5

Included Demos work ok (all of them)

Also tried briefly on a Windows 10 system with Chrome with the same results. All demos worked.


Is there a way to put user-entered data into a variable?

I had been using PROMPT to capture user input data as a variable...

Code: Select all
PROMPT "Please enter text:" !VAR1


Unfortunately, PROMPT no longer works with the latest Chrome update.

I've come up with the following workaround that EXTRACTs the user input from an html form I created. But I can't pass that data along because EXTRACT is not a variable and IEXTRACT does not work within a TAG. I've spent a lot of time with this and I haven't found a way to do this. Is there a way to load TAG EXTRACT'd data into a variable?

This is what I am trying to do...

Code: Select all
URL GOTO=C:\Users\username\Desktop\FormTest.html
TAG POS=1 TYPE=INPUT:TEXT FORM=NAME:form1 ATTR=NAME:abc EXTRACT=TXT

SET !VAR1 {{!EXTRACT}}

TAB OPEN NEW
TAB T=2
URL GOTO=http://www.forvo.com/word/{{!VAR1}}/#ar


No luck with this, even though I found some demo samples that said it should work.

Any suggestions would be appreciated. Thank you.

iimfun wrote:
Raisins wrote:I had been using PROMPT to capture user input data as a variable...

Code: Select all
PROMPT "Please enter text:" !VAR1


Unfortunately, PROMPT no longer works with the latest Chrome update.

I encountered the same problem. Here is my workaround for that

Code: Select all
SET !VAR1 EVAL("prompt('Please enter text:');")
PROMPT {{!VAR1}}

Raisins wrote:Thank you. This works

Hum..., for Cross-Browser Compatibility, @iimfun's Workaround will NOT work on FF (tested on v8.8.2 and v8.9.7 for FF: => "ReferenceError: prompt is not defined, line 5 (Error code: -1001)"), see the following 2 related Threads for other Workarounds that should(?) work in all Browsers...:
- Displaying window.alert()
- PROMPT Messagebox - Yes - No - Cancel (end)
- (F)CIM = (Full) Config Info Missing: iMacros + Browser + OS with all 3 Versions...
- I usually don't even read the Question if that (required) Info is not mentioned...
- Script & URL usually help a lot for a more "educated" Help...
chivracq
 
Posts: 5996
Joined: Sat Apr 13, 2013 6:07 am
Location: Amsterdam (NL)


Return to Data Extraction and Web Screen Scraping

Who is online

Users browsing this forum: No registered users and 1 guest

-->