Eric 15 Posted June 6, 2010 Report Share Posted June 6, 2010 Need help here.. I am not sure why the %profilelink $list item don't save to list anymore since I changed the command from scrape page to scrape href. Previously the command works, and the $list item is saved to the file correctly. I checked that the $profile link content is correctly generated by inserting a save to file to desktop, but the content can't saved to another list %linkreport as a item in it?What's wrong with this command now? Previously it works.. http://content.screencast.com/users/erickz/folders/Jing/media/6ab55370-cc78-44aa-8125-ba894251c172/2010-06-07_0627.png http://content.screencast.com/users/erickz/folders/Jing/media/5e593c70-a50a-449d-a33a-36fee6b426cd/2010-06-07_0626.png http://content.screencast.com/users/erickz/folders/Jing/media/3a3db2f8-fa51-4478-9c81-f78cd3d2501b/2010-06-07_0624.png Quote Link to post Share on other sites
Eric 15 Posted June 7, 2010 Author Report Share Posted June 7, 2010 Okay.. I have confirm the problem here..There is some bug in the add to list function using scrape href, sometimes there will be a blank line at the start of the list, thus causing the scrape href link to be inserted into the list at the second line, where the first line is a blank line, so this will caused problem when we need to extract the list item out, as the first line item is a blank line! I have show a sample script below attached image, just go to any page and then input a unique anchor text keyword, and you will noticed that sometimes, the link extracted will be at the second line, after a blank line item. Please advise on this, I can't proceed and solve my current list issue.. Please help.. http://content.screencast.com/users/erickz/folders/Jing/media/74db73a3-b584-4c2b-b3bb-9f3895af2fd4/2010-06-07_1250.pnghttp://content.screencast.com/users/erickz/folders/Jing/media/9acc0616-910c-4f5f-b154-df9b260cb532/2010-06-07_1250.png Quote Link to post Share on other sites
Net66 54 Posted June 7, 2010 Report Share Posted June 7, 2010 Just pop in an if node to detect and deal with it? if list item 0(%yourlist)=$nothingremove from list (%yourlist) 0 Andy Quote Link to post Share on other sites
Eric 15 Posted June 7, 2010 Author Report Share Posted June 7, 2010 Just pop in an if node to detect and deal with it? if list item 0(%yourlist)=$nothingremove from list (%yourlist) 0 Andy Hi Andy, thanks for the reply. Actually I have already add in a similar command to check for the blank list item and remove it when I noticed the "remove" list item function But, I am puzzled why this happens as previously there is no such issue, I spend almost 2-3 hrs trying to figure out what went wrong when I changed the scrape href function and it happened that its not the scrape error but random blank item occuring in save list function. So I need to check with the ubot team if this is indeed a error or bug? It would be better if the ubot team take a look at this.. Quote Link to post Share on other sites
alcr 135 Posted June 7, 2010 Report Share Posted June 7, 2010 Can you upload a sample script? I can't duplicate it / understand the problem for some reason. Quote Link to post Share on other sites
Eric 15 Posted June 8, 2010 Author Report Share Posted June 8, 2010 Can you upload a sample script? I can't duplicate it / understand the problem for some reason. Hmm, the example is shown on #2 thread.. Anyway I have just make a sample and attached hereby.The issue I faced, is that when I scraped a innertext attribute and add the href attribute to a list, by default the link should be saved onto the first line of the list. But there are times that the link is saved onto the second line of the list instead. I am not sure why this happens, probably due to differences in the ahref html code, maybe? Eg: Navigate to ubotstudio dot com site Then just plug in these few anchor texts :Features & BenefitsScreenshotsUser ReviewsFAQsPurchase Now each time inside the UI field, all the links are saved correctly onto the first line of the list, except for "Purchase Now", whereby the link is saved onto a second line, the first line is a blank line. This happens to other websites I am scraping too. Need advise on this.. Currently, I am adding a node to remove the empty first line for this purpose.sample.ubot Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.