自動更新(オートリロード)のブックマークレット



W-ZERO3Opera 8.5 Mobile には、ページの自動更新(auto reload)の機能が実装されていなかったので、Bookmarkletを作った。


W-ZERO3Opera は、ブックマークレットからローカルに置いたhtmlを読むことが出来ないので京ぽん用のブックマークレットとは、別物になってますが、ほとんど、同じ考え方で使えます。

javascript:(function(){var T=prompt('更新間隔?(秒)','60');if(T&&!isNaN(T)){var F='<html><frameset rows="*,0"><frame src="'+location+'"><frame></frameset></html>';var W=open();with(W.document){write(F);close();}var H='<html><script>function R(){parent.frames[0].location="'+location+'";}setInterval("R()",'+T*1000+');</script></html>';with(W.frames[1].document){write(H);close();}}})();


追記
PC の OperaFirefoxIE でも使えます。
さらに追記
アドエス 」 こと 「 Advanced/W-ZERO3[es] WS011SH 」の Opera for Windows Mobile Ver8.7で自動更新したい方は、
http://d.hatena.ne.jp/borbis/20070804
http://d.hatena.ne.jp/borbis/20070805
をご覧ください。


さらに追記
Opera Mobile 10 で利用したい方は、
http://d.hatena.ne.jp/borbis/20100404
をご覧ください。