我收集的javascript document命令
引用地址:http://bbs.syue.com/thread-36034-1-1.html
直接在ie地址栏输入命令,回车,执行js。
这样也可以用来改变和获取元素的值和属性,很实用的。
查看cookie
javascript:alert(document.cookie)
直接编辑cookie
javascript:document.cookie=window.prompt("Linx Edit cookie:",document.cookie);void(0);
打不开〖internet选项〗的时候
javascript:window.external.showBrowserUI("PrivacySettings",null)
显示网页源代码
javascript:s=document.documentElement.outerHTML;document.write('<body></body>');document.body.innerText=s;
网页放大1.5倍
javascript:void(s=document.body.style);void(z=s.getAttribute('zoom'));if(z){s.setAttribute('zoom',(parseInt(z)+50)+'%');}else
s.setAttribute('zoom','150%')
网页缩小0.5倍
javascript:void(s=document.body.style);void(z=s.getAttribute('zoom'));if(z){s.setAttribute('zoom',(parseInt(z)-50)+'%');}else
s.setAttribute('zoom','50%')
右键另存为
javascript:document.write('<a href="http://www.baidu.com/img/baidu_logo.gif">右键另存为</a>');
获取页面所有链接
javascript:var a="";for(i=0;i<document.links.length; i++ )a+=document.links(i).href+"<br/>";document.write(a);
获取链接进来的css文件
1(源码)
javascript:str='';c=document.styleSheets;for(i=0;i<c.length;i++){o=c[i];if
(o.href=='')continue;str+='==========
';str+=o.href;str+='<br><xmp>\n';str+=o.cssText;str+='</xmp><br><br>\n';};document.write(str);
2(地址)
javascript:str='<HTML><HEAD><BASE
HREF="';str+=document.URL;str+='"></HEAD><BODY><br>\n';c=document.styleSheets;for(i=0;i<c.length;i++){o=c[i];if
(o.src=='')continue;str+='<a
href="';str+=o.href;str+='">';str+=o.href;str+='</a><br>\n';};str+='</BODY></HTML>';document.write(str);
获取链接进来的js文件
javascript:str='<HTML><HEAD><BASE
HREF="';str+=document.URL;str+='"></HEAD><BODY><br>\n';c=d
相关文档:
javascript parseInt is broken
I was debugging some strange errors in a date conversion function I was writing, and I stumbled upon something that amazed me... a strange bug in parseInt
>>>parseInt('06')
6
>>>parseInt('07')
7
>>>parseInt('08')
0
>>>parseInt ......
document 文挡对象 - JavaScript脚本语言描述
---------------------------------------------------------------------
注:页面上元素name属性和JavaScript引用的名称必须一致包括大小写
否则会提示你一个错误信息 "引用的元素为空或者不是对象"
------------------------------------------- ......
<mce:script language="javascript" type="text/javascript"><!--
//需要读取的xml文件
var uRl = "jsReadXml.xml";
var xmlDoc;
//初始化,给上述定义变量赋值
// function showcurcity(){
if(window.ActiveXObject)
{
xmlDoc=new ActiveXObject("Microsoft.XMLDOM&q ......
本文来自http://q.yesky.com/group/review-17634017.html,另外还添加一些里面技术的链接。
离线事件(Online and offline events):
https://developer.mozilla.org/En/Online_and_offline_events
https://bug336359.bugzilla.mozilla.org/attachment.cgi?id=220609
http://ejohn.org/blog/offline-events/
postMessage ......
参加JavaScript面试,必须搞懂的问题(推荐)
一. JavaScript中的对象.
JavaScript中的Object是一组数据的key-value的集合, 有点类似于Java中的HashMap, 所有这些数据都是Object里的property.
通常情况下, JavaScript中建立一个对象用"new"加上constructor function来实现.
如new Date(), new Object()等.
var bo ......