易截截图软件、单文件、免安装、纯绿色、仅160KB

[翻译]High Performance JavaScript(005)

第二章  Data Access  数据访问
    One of the classic computer science problems is determining where data should be stored for optimal reading and writing. Where data is stored is related to how quickly it can be retrieved during code execution. This problem in JavaScript is somewhat simplified because of the small number of options for data storage. Similar to other languages, though, where data is stored can greatly affect how quickly it can be accessed later. There are four basic places from which data can be accessed in JavaScript:
    经典计算机科学的一个问题是确定数据应当存放在什么地方,以实现最佳的读写效率。数据存储在哪里,关系到代码运行期间数据被检索到的速度。在JavaScript中,此问题相对简单,因为数据存储只有少量方式可供选择。正如其他语言那样,数据存储位置关系到访问速度。在JavaScript中有四种基本的数据访问位置:
Literal values  直接量
Any value that represents just itself and isn't stored in a particular location. JavaScript can represent strings, numbers, Booleans, objects, arrays, functions, regular expressions, and the special values null and undefined as literals.
直接量仅仅代表自己,而不存储于特定位置。 JavaScript的直接量包括:字符串,数字,布尔值,对象,数组,函数,正则表达式,具有特殊意义的空值,以及未定义。
Variables  变量
Any developer-defined location for storing data created by using the var keyword.
开发人员使用var关键字创建用于存储数据值。
Array items  数组项
A numerically indexed location within a JavaScript Array object.
具有数字索引,存储一个JavaScript数组对象。
Object members  对象成员
A string-indexed location within a JavaScript object.
具有字符串索引,存储一个JavaScript对象。
    Each of these data storage locations has a particular cost associated with reading and writing operations involving the data. In most cases, the performance difference between accessing information from a literal value versus a local variable is trivial. Accessing info


相关文档:

HTML+Javascript+XML


上面所说有关HTML的内容非常少又简单,但对已经了解的人来说就是没用的.
如有问题可到权威网 http://www.html.com/ 上查看
以下开始说说关于XML的一些知识.
XML也是标记语言,可它是自定义的,没有已给定格式.不具体说它,给出例子就可明了.

<NAME>TOM</NAME>
<SEX>M</SEX>
以上内容的< ......

Javascript导出Excel

<!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="text/html; ......

JavaScript利用DOM给页面添加内容

自定义一个log函数,输出传入函数的对象或者信息.
Log.js
// JScript source code
function
log(category, message, object) {
// If this category is explicitly disabled, do nothing
if
(log.options[category + "Disabled
"]) return
;
// Find the container
var
id = categ ......

JavaScript 动态数组 实例


<html>
<body>
<script type="text/javascript">
//方法一
var num_arr= [];
for (var i = 0 ; i < 10 ;  i ++)
{
  num_arr[i] = i; 
}
document.write(num_arr+'</br>');
//方法二
var obj_arr=new Array();
obj_arr[6]='ss';
document.write(obj_arr.len ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号