首次加载greasemonkey脚本时,是否只能显示一次警报?我希望它告诉用户脚本已升级到新版本。
答案 0 :(得分:1)
阅读最后存储的版本并检查实际版本:
+++++ request_hiscores_for() running +++++10032
<type 'str'>
using request_hiscores_for()32
using request_hiscores_for()32
Requesting hiscores for BLA using request_hiscores_for()
----- request_hiscores_for() ending ------
+++++ request_hiscores_for() running +++++123 Lvs 2 Go
<type 'str'>
using request_hiscores_for() Lvs 2 Go
using request_hiscores_for() Lvs 2 Go
Requesting hiscores for BLA using request_hiscores_for()
----- request_hiscores_for() ending ------
当您更改脚本时,当然应该更新所有三个版本实例。