We could also add a new function and call it from doWeb in the multiple item cases, i.e. `ZU.processDocuments(articles, selectFrame);` where

```
function selectFrame(doc, url) {
	if (url.indexOf("target=results_listview_resultsNav") == -1 ) {
		var frames = doc.getElementsByTagName("frame");
		var gotoUrl;
		for (var i=0; i<frames.length; i++) {
			if (frames[i].src.indexOf("target=results_listview_resultsNav") != -1) gotoUrl=frames[i].src;
		}
		ZU.processDocuments(gotoUrl, scrape);
	} else {
		scrape(doc,url);
	}
}
```

The scrape function would then just the else part. In this way no infinite loop should be possible. What do you think? I don't know how to substitute the `processDocuments` with `doGet` here: how do we receive a document object?