雅虎收藏+是我经常用的网络收藏服务,但雅虎收藏提供的书签栏按钮不能在Firefox下工作,是美中不足的地方。我对它进行了一番修改,使它可以在Firefox下正常工作。
书签代码如下:
javascript:d=document;w=window;mywebya=encodeURIComponent(d.location.href);mywebyt=encodeURIComponent(d.title);mywebyd=encodeURIComponent(w.getSelection?w.getSelection().toString():d.getSelection?d.getSelection():d.selection.createRange().text);open(‘http://myweb.cn.yahoo.com/popadd.html?src=iebookmark&url=’+mywebya+’&title=’+mywebyt+’&summary=’+mywebyd,’Yahoo’,’modal=1,status=1,scrollbars=1,toolbar=0,resizable=1,width=780,height=455,left=’+(screen.width-730)/2+’,top=’+(screen.height-425)/2);void(0);
原来的代码是(不能正常工作):
javascript:mywebyx=document;mywebya=encodeURIComponent(mywebyx.location.href);mywebyt=encodeURIComponent(mywebyx.title);mywebyd=encodeURIComponent(document.selection.createRange().text);open(‘http://myweb.cn.yahoo.com/popadd.html?src=iebookmark&url=’+mywebya+’&title=’+mywebyt+’&summary=’+mywebyd,’Yahoo’,’modal=1,status=1,scrollbars=1,toolbar=0,resizable=1,width=780,height=455,left=’+(screen.width-730)/2+’,top=’+(screen.height-425)/2);void(0);
评论前必须登录!
注册