Jump to content
UBot Underground

Recommended Posts

I am using the scrape attribute file to scrape information from a website and save it to a list

 

However, the issue I am running into is the scraped data is populating the list as one item.

 

So, when I try to call the information using the next item function it is populating the field with all of the items scraped from the previous scraped attribute function as just 1 item.

 

So if there are 7 items scraped instead of the script seeing it as 7 items it is seeing all 7 as 1 item.

 

How do I get the items that are scraped to appear as separate items and not just one single item.

 

For instance, this is what the debugger looks like…

 

 

%scraped: 1 items

 

info1

info2

info3

info4

info5

info6

info7

 

When I save the scraped list to a file the items appear on a new line. so my guess would be that the program should read each item as a separate item. However, it is reading all of the items as one item.

 

I have also tried saving the list to a file and then calling that file using the add list to list function and I am running into the same issue.

 

Hopefully my description of this make sense :-)

Link to post
Share on other sites

I had the same problem, it's holding all the data as 1 item.

The solution I use :

 

define save_Add_delete {
   save to file("{$special folder("Application")}/list.txt", %list_name)
   comment("Saves list to application Folder")
   add list to list(%new_list, $list from file("{$special folder("Application")}/list.txt"), "Delete", "Global")
   comment("Adds to a new list, this time each line is a list item.")
   delete file("{$special folder("Application")}/list.txt")
   comment("Deletes the transition file, you don\'t need it, but sometimes its worth doing")
}

 

A quick trip into ubot, this works also and is a lot less time

 

add list to list(%list_to_add_to, $page scrape("what to scrape left side", "right side"), "Delete", "Global")

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...