<!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; charset=gb2312" />
<title>无标题文档</title>
</head>

<body>
<p id="demo"></p>

<script>
 var person = {
   firstName: "John",
    lastName : "Doe",
    id       : 5566,
fullName : function(){ //  怎样创建訪问对象方法
  // return this.firstName + " " + this.lastName;
   return this.firstName + " " + this.lastName;
}
 
 };
 
 document.getElementById('demo').innerHTML = person.fullName();//调用对象方法
</script>
</body>
</html>

最新文章

  1. block
  2. 通过泛型数据,操作SQL数据库
  3. 操作TAB文件和TStringGrid赋值;
  4. (笔记)Linux内核学习(八)之定时器和时间管理
  5. 弦图的判定MCS算法(zoj1015)
  6. ZOJ 3804--解题报告
  7. JUC之Atomic系列12大类实例讲解和原理分解
  8. appcompat_v7/res/values-v21/themes_base.xml No resource found that matches the given name
  9. 基于NodeJs的网页爬虫的构建(二)
  10. 字符(汉子)转换为ASCII
  11. QTestLib Tutorial
  12. 25_Downloading An Image
  13. Java对象序列化/反序列化的注意事项
  14. 【UML 建模】活动图介绍
  15. 【Spring】手写Spring MVC
  16. 100-days: twenty-five
  17. docker简单搭建gitlab
  18. 使用vmware vconverter从物理机迁移系统到虚拟机P2V(多图)
  19. Python模拟人猜数过程(折半查找)
  20. P3810 -三维偏序(陌上花开)cdq-分治

热门文章

  1. UI各种小控件的用法
  2. HDU 2874 LCA离线算法 tarjan算法
  3. MapReduce编程之倒排索引
  4. Mina airQQ聊天 client篇(三)
  5. Django -&amp;gt; debug模式下的静态文件服务(/media/)
  6. System.DirectoryServices Namespace
  7. CentOS 7 安装 vmware tools 提示The path &quot;&quot; is not a valid path to the 3.10.0-957.el7.x86_64 kernel headers.
  8. category与协议的不同
  9. Oracle 新手语法记录
  10. .NET MVC权限设计思考之切入点