Mouse wheel and page height problem?

clipboard.png

this code controls the scroll wheel to scroll down until the entire page is loaded

I have a little question about the code browser.execute_script (js1) > = old_scroll_height: .
should I not take the equal sign here, or it will become an endless loop?

add: python.jobbole.com/89123/-sharpcomment-95227" rel=" nofollow noreferrer "> source code from Bole online

Mar.16,2021

Yes, but you don't need while. Just scroll once

if you want to roll the page until it is fully loaded, it cannot be removed, because the network request may be very long when you roll to the end, and the height of the page remains the same for a long time, so you have to roll when it is equal.

the termination condition can be set to equal height for several times, and the number of arrivals is considered to be all rolled

.
Menu