Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (defun new-page-iterate (iterfunc url)
- (let* ((threadbase (ppcre:regex-replace "\\?[^&]+"
- (ppcre:regex-replace "&page=(last|first|[0-9]+)"
- url
- "")
- ""))
- (page (get-parsed-page (make-new-url threadbase '(("page" . 1))))))
- (reverse (loop as nextpage = (extract-next-page-number page)
- append (reverse (funcall iterfunc page))
- while nextpage
- do (setq page (get-parsed-page (make-new-url nextpage)))))))
Advertisement
Add Comment
Please, Sign In to add comment