2 text selector in one row?

why the data i got always missing one,

title no author, no title with author

{"_id":"wwend","startUrl":["https://www.worldswithoutend.com/books_hugo_index.asp?emulate=&Page=1&PageLength=100"],"selectors":[{"id":"1reportlist","type":"SelectorElement","selector":"div#reportlist","parentSelectors":["_root"],"multiple":false,"delay":0},{"id":"awardslisting","type":"SelectorElement","selector":"div.awardslisting \t","parentSelectors":["1reportlist"],"multiple":true,"delay":"500"},{"id":"title","type":"SelectorText","selector":"p.title a","parentSelectors":["awardslisting"],"multiple":true,"regex":"","delay":"100"},{"id":"author","type":"SelectorText","selector":"p.author a","parentSelectors":["awardslisting"],"multiple":true,"regex":"","delay":"100"}]}

Hi!

The scraping can be done with a different approaches in your case, for example using a table selector.

You did use 'multiple' option in a little wrong way, as if you have an element selector (without 'multiple' selected), and some selectors inside with 'multiple' option enabled, will result in a single line (with nothing shown). If you set mutiple on both Element and the selectors inside, it will result with actually 2 columns of data, that go one after another instead of gong in one line simultaneously.

If you want two simultaneous columns of data, you have to select 'Multiple' within Element selecetor, and disable 'Multiple' within selectors inside, as an Element selector will pick all the results with 'multiple' enabled.

BTW you've got pretty much precise selectors, just a slight edit and the table is shown without unnecesary data.

{"_id":"test2","selectors":[{"parentSelectors":["Overview"],"type":"SelectorText","multiple":false,"id":"Title","selector":"p.title","regex":"","delay":""},{"parentSelectors":["Overview"],"type":"SelectorText","multiple":false,"id":"Author","selector":"p.author","regex":"","delay":""},{"parentSelectors":["_root"],"type":"SelectorElement","multiple":true,"id":"Overview","selector":"tr:nth-of-type(n+3) td:nth-of-type(n+2) tr td","delay":""}],"startUrl":["https://www.worldswithoutend.com/books_hugo_index.asp?emulate=&Page=1&PageLength=100"]}

If you want it to go through rest of the pages left, you have to use brackets [ ]

An example, if you want to scrape all the results from page 1 to 5 your sitemap will look like this:

{"_id":"test2","selectors":[{"parentSelectors":["Overview"],"type":"SelectorText","multiple":false,"id":"Title","selector":"p.title","regex":"","delay":""},{"parentSelectors":["Overview"],"type":"SelectorText","multiple":false,"id":"Author","selector":"p.author","regex":"","delay":""},{"parentSelectors":["_root"],"type":"SelectorElement","multiple":true,"id":"Overview","selector":"tr:nth-of-type(n+3) td:nth-of-type(n+2) tr td","delay":""}],"startUrl":["https://www.worldswithoutend.com/books_hugo_index.asp?emulate=&Page=[1-5]&PageLength=100"]}