我正在尝试编写一个执行以下操作的程序......
我是applecript的初学者......但是可以学习完成这个项目所需的一切。有人能告诉我一个我想写的代码示例吗?
答案 0 :(得分:0)
set urls to "http://stackoverflow.com/questions/18069198
http://stackoverflow.com"
--set urls to read "/tmp/input.txt" as «class utf8»
repeat with u in paragraphs of urls
tell application "Safari"
activate
open location u
delay 1
tell document 1
repeat while do JavaScript "document.readyState" is not "complete"
delay 0.1
end repeat
do JavaScript "document.querySelectorAll('#hlogo a')[0].click()"
end tell
end tell
tell application "System Events" to keystroke return
end repeat