Heim > Web-Frontend > js-Tutorial > Hauptteil

10个实用的脚本代码工具_javascript技巧

WBOY
Freigeben: 2016-05-16 18:28:17
Original
1220 Leute haben es durchsucht

下面介绍10个实用的
浏览辅助
Tidy Read

复制代码 代码如下:
javascript:(function(){var s=document.createElement("script");s.charset="gb2312";s.language="javascript";s.type="text/javascript";s.src="http://tidyread.com/tidyread.js?u="+encodeURIComponent(document.location.href)+"&t="+encodeURIComponent(document.title);document.body.appendChild(s)})();

将那些乱糟糟的页面清理干净,更加可以自由设置喜好,很强大。

Show Password
复制代码 代码如下:
javascript:(function(){var s,F,j,f,i; s = ""; F = document.forms; for(j=0; j

查看网页上显示为*****的密码。觉得很有用处,比如当Chrome记住密码,而你忘了时...

Dictionary.com
复制代码 代码如下:
javascript:(function(){ q=document.getSelection(); if(!q) q=prompt('Dictionary.com Search:'); if(q) location.href='http://dictionary.reference.com/search?r=1&q='+escape(q); })()

翻译选中的单词,美中不足的是英英翻译,适合英语有一定水平的朋友。

restore selecting
复制代码 代码如下:
javascript:(function() { function R(a){ona = "on"+a; if(window.addEventListener) window.addEventListener(a, function (e) { for(var n=e.originalTarget; n; n=n.parentNode) n[ona]=null; }, true); window[ona]=null; document[ona]=null; if(document.body) document.body[ona]=null; } R("click"); R("mousedown"); R("mouseup"); R("selectstart"); })();

有些网站禁止选择文本,它可以恢复之。貌似chrome用不了。

清除网站的cookies
复制代码 代码如下:
javascript:(function(){C=document.cookie.split("; ");for(d="."+location.host;d;d=(""+d).substr(1).match(/\..*$/))for(sl=0;sl

清除网站的cookies,Chrome用不了。

开发者工具

Reload CSS
复制代码 代码如下:
javascript:void(setInterval(function(){var qs='?'+new Date().getTime(),l,i=0;while(l=document.getElementsByTagName('link')[i++]){if(l.rel&&'stylesheet'==l.rel.toLowerCase()){if(!l._h)l._h=l.href;l.href=l._h+qs}}},2000));

让网页不断的重载CSS。

Spry Media
复制代码 代码如下:
javascript:function fnStartDesign(sUrl) {var nScript = document.createElement('script');nScript.setAttribute('language','JavaScript');nScript.setAttribute('src',sUrl);document.body.appendChild(nScript);}fnStartDesign('http://www.sprymedia.co.uk/design/design/media/js/design-loader.js');

十分强大的工具。包含:网格,标尺,单位测量,十字线。建议web设计师试一下。

Layout Grid
复制代码 代码如下:
javascript:void(myDiv=document.createElement('div'));void(myBody=document.getElementsByTagName('body')[0]);void(myDiv.style.background='url(http://www.andybudd.com/images/layoutgrid.png)');void(myDiv.style.position='absolute');void(myDiv.style.width='100%');void(myDiv.style.height='100%');void(myDiv.style.top='0');void(myDiv.style.left='0');void(myBody.appendChild(myDiv));

生成漂亮的网格。

Print Screen
复制代码 代码如下:
javascript:window.location='http://aviary.com/' + location.href;

又一个推荐的工具。截取当前网页,更可以自动进入aviary.com编辑该图片。

Download as PDF
复制代码 代码如下:
javascript:void(window.open('http://www.pdfdownload.org/web2pdf/Default.aspx?left=0&right=0&top=0&bottom=0&page=0&cURL='+document.location.href));

存储网页为pdf文件。

再提一句,Spry Media真的很好用。

偶尔因为网速慢,可能导致不能正常运行,其它的都是经过测试的,效果不错。

使用后,先打开想要操作的页面, 然后复制脚本代码,拷贝到IE地址栏中,回车运行即可(不能点后面的重新加载)
Verwandte Etiketten:
Quelle:php.cn
Erklärung dieser Website
Der Inhalt dieses Artikels wird freiwillig von Internetnutzern beigesteuert und das Urheberrecht liegt beim ursprünglichen Autor. Diese Website übernimmt keine entsprechende rechtliche Verantwortung. Wenn Sie Inhalte finden, bei denen der Verdacht eines Plagiats oder einer Rechtsverletzung besteht, wenden Sie sich bitte an admin@php.cn
Beliebte Tutorials
Mehr>
Neueste Downloads
Mehr>
Web-Effekte
Quellcode der Website
Website-Materialien
Frontend-Vorlage
Über uns Haftungsausschluss Sitemap
Chinesische PHP-Website:Online-PHP-Schulung für das Gemeinwohl,Helfen Sie PHP-Lernenden, sich schnell weiterzuentwickeln!