1 window事件2
window.onload=function(){alert("页面创建中****");};3
window.onunload=function(){alert("页面卸载中****");};4 window.onbefor...
分类:
Web程序 时间:
2014-05-09 04:34:03
阅读次数:
397
/** * josn化表单数据 * @name baidu.form.json * @function
* @grammar baidu.form.json(form[, replacer]) * @param {HTMLFormElement} form
需要提交的表单元素 * @p...
分类:
其他好文 时间:
2014-05-09 04:21:52
阅读次数:
287
function myfunction(msg) print("this is msg fun "
.. msg);endlocal fun =_G["myfunction"];if fun then fun("is ok");end
分类:
其他好文 时间:
2014-05-09 04:18:05
阅读次数:
1155
在C++的TR1中(Technology
Report)中包含一个function模板类和bind模板函数,使用它们可以实现类似函数指针的功能,但却却比函数指针更加灵活,特别是函数指向类
的非静态成员函数时。可以参考Scott Meyers. >. Item 35.下面具体说明其使用方法。一、指向全...
分类:
其他好文 时间:
2014-05-09 03:44:32
阅读次数:
289
本篇介绍angular中元素的迭代: 4.1.迭代
{{$index+1}}{{student.name}}{{student.score}} function StudentList ($scope){
$scope.students = [{"...
分类:
其他好文 时间:
2014-05-09 03:44:07
阅读次数:
183
Consider a simple function that adds the first
N integers. (e.g.sum(5) = 1 + 2 + 3 + 4 + 5 = 15).Here is a simple Python
implementation that uses recu...
分类:
其他好文 时间:
2014-05-08 17:35:09
阅读次数:
286
/**
* 闭包的作用域
*/
fn1(); //fn1 能够执行,不会报错,对于通过function func_name()这种写法来定义的函数,永远都会被最先初始化。
function fn1(){
console.log("fn1");
}
fn2(); //报错:fn2 is not a function
/**
*使用如下方式定义函数,不会被先执行,如果在...
分类:
Web程序 时间:
2014-05-08 16:22:48
阅读次数:
367
window.onload=function() {
var img=document.getElementById("img").children;
var lis=document.getElementById('ul').getElementsByTagName("li"); //这里是获取需要执行动态效果的demo
...
分类:
编程语言 时间:
2014-05-08 16:06:15
阅读次数:
386
使用VLD测有没内存泄露的时候,出现(File and line number not available): (Function name unavailable)
查看VS控制台,发现
已加载“C:/WINDOWS/system32/dbghelp.dll”
说明VS加载了WINDOWS的dll而不是最新的VLD的dbghelp.dll
解决方案:
只需把VLD 安装路径下...
分类:
其他好文 时间:
2014-05-08 15:41:04
阅读次数:
354
在lua中创建一个Actor对象function Actor.new() local temp
= {} setmetatable(temp, Actor) temp.x = 10 temp.y = 20 return tempendobj =
Actor.new()那么obj.x = 1...
分类:
其他好文 时间:
2014-05-08 15:04:41
阅读次数:
348