Time of Update: 2018-12-05
正在執行的函數和調用它的函數的參數。 [function.]arguments[n] 參數function :選項。當前正在執行的 Function 對象的名字。 n :選項。要傳遞給 Function 對象的從0開始的參數值索引。 說明
Time of Update: 2018-12-05
加入_d=document;eval_r('var document=_d')解說因為 document 是 window 的子物件,對 IE 來說,要使用 document ,必須經過 window ,而上面的方法是讓 document 成為一個獨立的對象,不必透過 window ,因此速度就提升了。eval_r((function(props) { var code = []; for (var i = 0, l = props.length;i<l;i++){ var prop =
Time of Update: 2018-12-05
<script> function request(key) { if(typeof(this)=="undefined")return false; if(this.length>0) { var s = this.split("&"); for(var i in s) { var sp=s[i].split("=") if(sp[0]==key)return(sp[1]); } return false; } else return false }
Time of Update: 2018-12-05
object.setCapture() 當一個object的被 setCapture 後,他的方法將會被繼承到整個文檔進行捕獲。 當不需要把方法繼承到整個文檔捕獲時,要用 object.releaseCapture() Mozilla 也有類似的功能,方法稍微不同 window.captureEvents(Event.eventType) window.releaseEvents(Event.eventType)Event 是Mozilla特殊的一個object.
Time of Update: 2018-12-05
Location.href 返回整個當前url,若對其賦值: location.href="http://www.sina.com.cn"則跳轉其url location.host 返回網域名稱和連接埠號碼,如:www.sina.com.cn:80 lcation.hostname 返回網域名稱 location.port 返回連接埠 location.pathname 返回網域名稱後第一個斜框後的字串 location.hash 跳到本頁的某個錨 location.search
Time of Update: 2018-12-05
使IE和FireFox事件停止的方法:<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content=
Time of Update: 2018-12-05
一、概述 javascript函數劫持,也就是老外提到的javascript hijacking技術。大概這樣寫的: window.alert = function(s) {}; 覺得這種用法很巧妙新穎,和API Hook異曲同工,索性稱之為javascript function hook,也就是函數劫持。通過替換js函 數的實現來達到劫持這個函數調用的目的,一個完整的hook alert函數例子如下: <!--1.htm--> <script
Time of Update: 2018-12-05
Jsunit 就是 Junit 的javascript 版本,下載並解壓Jsunit zip,大部分的核心檔案都在 jsunit/app 目錄下,兩個最基本的檔案: . jsUnitCore.js -- 每個測試檔案都要引用它 . testRunner.html -- 用來運行具體的jsunit 測試(1) 起步例子: 在Jsunit解壓後的同級目錄下建立兩個檔案,目錄結構: |-- jsunit |-- simple.js |-- simple_test.html寫完後運行
Time of Update: 2018-12-05
下載網址:http://code.google.com/p/trimpath/ 轉自:http://bbs.chinaunix.net/viewthread.php?tid=735901官方網址:http://trimpath.com/project/wiki/JavaScriptTemplates Trimpath JavaScript 是個輕量級的,基於JavaScript的,跨瀏覽器,採用APL/GPL開放原始碼協議的,可以讓你輕鬆進行基於模板編程方式的純JS引擎。 它有如下的特點: 1
Time of Update: 2018-12-05
向javascript尋寶 用.net開發web這一年多來,漸漸體會到javascript的無窮魅力和效用,今日向javascript尋得了一些寶貝。。。1。有個頁面要通過一個錄入textbox的第一碼來實現另一個dropdownlist的動態新增,相關寫法:function rat(obj,obq) { //alert(obj); var xh=new ActiveXObject("Microsoft.XMLHTTP"); xh.open("POST","qas03.aspx?ckind="
Time of Update: 2018-12-05
最近項目開發中需要子視窗和父視窗互動的內容,基本上無非就是把子視窗的資訊傳遞給父視窗,並且關閉自己等等,或者是父視窗把自己的資訊傳遞給子視窗等等。1。父視窗傳遞資訊給子視窗看代碼執行個體:<script language=javascript>function output(){//擷取父視窗的文本資訊賦值給textvar text = document.abc.text.value;//開啟子視窗,並且把操作控制代碼賦值給win變數,以下所有操作都是針對win對象的var win
Time of Update: 2018-12-05
<script>function Dec2Any(str,num){ //coded by windy_sk <windy_sk@126.com> if(!/\d+/.test(str)) return NaN; if(!/\d+/.test(num)) return NaN; var num=eval(num); if(num>36 || num<2) return NaN; var
Time of Update: 2018-12-05
<style>BODY { FONT-SIZE: 9pt;}TD { FONT-SIZE: 9pt; LINE-HEIGHT: 11pt;}input { FONT-SIZE: 9pt;}SELECT { FONT-SIZE: 9pt; TEXT-ALIGN: center; WIDTH: 100px;}span { FONT-SIZE: 12pt;}</style><script language=JavaScript>/*All Files are
Time of Update: 2018-12-05
<!--All Files are Designed & Writen by Windy_sk, you can use it freely but ...YOU MUST KEEP THIS ITEM !Email: <a href="mailto:windy_sk@126.com">windy_sk@126.com</a>--><style>BODY {FONT-SIZE: 9pt;}table {FONT-SIZE:
Time of Update: 2018-12-05
<script language="javascript">//coded by windy_sk 20021013 <windy_sk@126.com>var ie = (document.getElementById && document.all);document.onkeyup = function(e) { if(ie) e = event; var keycode = e.keyCode; var realkey =
Time of Update: 2018-12-05
<style>.shadow1 { cursor:hand; position:absolute; top:50px; left:50px; width: 120px; height:120px; filter: dropshadow(color="#aaaaaa", offx=5, offy=5, positive=1) Alpha(Opacity=80);}.shadow2 { cursor:hand; position:absolute; top:200px; left:5
Time of Update: 2018-12-05
<script language="JavaScript1.2">/* This following code are designed and writen by Windy_sk <windy_sk@126.com> You can use it freely, but u must held all the copyright items!*/function
Time of Update: 2018-12-05
<HTML XMLNS:IE><meta http-equiv="Content-Type" content="text/html; charset=gb2312"><IE:Download ID="include" STYLE="behavior:url(#default#download)" /><title>Chromeless Window</title><SCRIPT
Time of Update: 2018-12-05
<link rel="stylesheet" href="/style.css" type="text/css"><style type="text/css">body { FONT-FAMILY: 宋體; FONT-SIZE: 9pt; SCROLLBAR-HIGHLIGHT-COLOR: buttonface; SCROLLBAR-SHADOW-COLOR: buttonface; SCROLLBAR-3DLIGHT-COLOR: buttonhighlight;
Time of Update: 2018-12-05
<!--All Files Design & Write by Windy_sk, you can use it freely but ...YOU MUST KEEP THIS ITEM !Email: <a href="mailto:windy_sk@126.com">windy_sk@126.com</a>--><html><head><title>Agenda</title><meta