Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
使用这个 Perl 模块,我将如何等待页面加载所有图像?(我正在尝试截取属于年龄的图像)
我试过$agent->success了,这只检查页面是否已加载(不检查图像)。
$agent->success
我认为模块中没有等待方法,但您可以检查元素是否可见并循环并等待它可见。
FOO: {while(1){ if($gent->is_visible($element)){ print "Image Downloaded\n"; last FOO; } else{ print "Downloading image...\n"; #This might print until image is downloaded sleep(10); } }}