zoukankan
html css js c++ java
Prototype学习笔记之-Ajax.Request
Prototype学习笔记,试用Ajax.Request,发现个问题,先记下来。
传了个参数进去,发现传中文会出现乱码!
<
script
src
="js/prototype.js"
type
="text/javascript"
></
script
>
<
script
type
="text/javascript"
>
function
ExecuteAjax()
{
var
id
=
$F('empid');
var
url
=
'http:
//
localhost/MyASPNETAJAX/AjaxDemo.aspx';
var
prams
=
'id
=
'
+
id;
var
myAjax
=
new
Ajax.Request(url,
{method:'get',parameters:prams,onLoading:loading,onComplete:ShowResult}
);
}
function
ShowResult(Result)
{
$('resultdiv').value
=
Result.responseText;
$('showloading').style.display
=
"
none
"
;
}
function
loading()
{
$('showloading').innerHTML
=
"
加载中,请稍后
.
"
;
}
</
script
>
<
select
id
="empid"
onchange
="ExecuteAjax()"
>
<
option
value
="
第一项
11"
>
第一项
</
option
>
<
option
value
="222222"
>
第二项
</
option
>
<
option
value
="333333"
>
第三项
</
option
>
</
select
>
<
textarea
id
="resultdiv"
cols
="60"
rows
="10"
></
textarea
>
<
div
id
="showloading"
></
div
>
查看全文
相关阅读:
Jmeter系列(64)- JMeter JSR223 入门
Jmeter系列(63)- Beanshell 入门
Jmeter系列(62)- 详解 JSON 断言
Jmeter系列(61)- 详解断言持续时间
Jmeter系列(60)- 详解响应断言
取球游戏|2012年蓝桥杯B组题解析第十题-fishers
夺冠概率|2012年蓝桥杯B组题解析第九题-fishers
密码发生器|2012年蓝桥杯B组题解析第八题-fishers
放棋子|2012年蓝桥杯B组题解析第七题-fishers
大数乘法|2012年蓝桥杯B组题解析第六题-fishers
原文地址:https://www.cnblogs.com/anson/p/552669.html
最新文章
Js中数组空位问题
组合模式
桥接模式
Vue路由Hash模式分析
scp命令
宝石与石头
Redis(一)-- 基础
Cypress系列(48)- and() 命令详解
Cypress系列(47)- 操作上一条命令返回结果的命令
Cypress系列(46)- then() 命令详解
热门文章
Performing Push Install adb: error: failed to get feature set: more than one 解决方案
Cypress系列(45)- cypress-skip-and-only-ui 插件详解
Cypress系列(44)- 命令行运行 Cypress
Cypress系列(43)- wait() 命令详解
Cypress系列(42)- visit() 命令详解
详解 Session 和 Cookie
Jmeter系列(68)- BeanShell 内置变量 prev
Jmeter系列(67)- BeanShell 内置变量 props
Jmeter系列(66)- BeanShell 内置变量 vars
Jmeter系列(65)- BeanShell 内置变量 ctx
Copyright © 2011-2022 走看看