zoukankan
html css js c++ java
历遍JavaScript对象
<
HTML
><
HEAD
>
<
TITLE
></
TITLE
>
<
META
NAME
="GENERATOR"
Content
="Microsoft Visual Studio"
>
<
META
HTTP-EQUIV
="Content-Type"
content
="text/html; charset=UTF-8"
>
<
script
language
=javascript
>
function
displayObject()
{
var
t
=
document.forms[
0
].Text1;
var
s
=
"
<center><b>历遍<font color=#ff0000>
"
+
t.value
+
"
</font>对象</b><br>
"
;
for
(
var
o
in
eval(t.value))
{
s
+=
"
<font color=#0000ff>
"
+
o
+
"
</font><br>
"
;
}
document.write(s
+
"
</center>
"
);
}
</
script
>
</
HEAD
>
<
BODY
>
<
center
><
font
color
=#0000ff
>
请输入对象名称
</
font
>
<
form
>
<
input
id
=Text1
name
=Text1
type
=text
>
<
br
>
<
input
id
=Button1
name
=Button1
type
=button
value
=历遍对象
onclick
="displayObject()"
>
</
form
></
center
>
</
BODY
></
HTML
>
查看全文
相关阅读:
HDU 1847
HDU 1717
KMP未优化模板、
Codeforces Round #340 (Div. 2) B. Chocolate
HDU 1042 N!
HDU 1018 Big Number
HDU 1031 Design T-Shirt
解决Windows 7删除执行过的 EXE、Bat文件有延迟的问题
修改Android手机的“虚拟机堆大小”和android:largeHeap来防止APP内存溢出问题
Android引用百度定位API第三方组件后导致其它.so文件无法正常加载的问题
原文地址:https://www.cnblogs.com/ghx88/p/370908.html
最新文章
可迭代对象、迭代器与生成器
多个装饰器叠加
装饰器
函数命名空间、作用域与闭包函数
Python之禅
函数
文件处理
ORACLE中CONNECT BY...START WITH...的使用
SQL获取时间段内的所有月份
FusionCharts之我用
热门文章
ASP MVC
一款比较好用的JS时间控件-laydate
java正则表达式匹配字符
SQL 左外连接,右外连接,全连接,内连接
pLSQL中文乱码问题
XML CDATA
javascript按钮点击事件问题
HDU 1326
HDU 1856
并查集模板、
Copyright © 2011-2022 走看看