<head runat="server">
<title>无标题页</title>
<script type="text/javascript" src="jquery-1.3.2.min.js"></script>
<script type="text/javascript">
$(document).ready(function(){
$("#left").click(function(){
var movevalue = $("#ListBox1 option:selected").val();
$("#ListBox2").append("<option>"+movevalue+"</option>");
$("#ListBox1 option:selected").remove();
})
$("#right").click(function(){
var movevalue = $("#ListBox2 option:selected").val();
$("#ListBox1").append("<option>"+movevalue+"</option>");
$("#ListBox2 option:selected").remove();
})
})
</script>
</head>
<body>
<form id="form1" runat="server">
<asp:ListBox ID="ListBox1" runat="server" Width="100" Height="200">
<asp:ListItem>1</asp:ListItem>
<asp:ListItem>2</asp:ListItem>
<asp:ListItem>3</asp:ListItem>
<asp:ListItem>4</asp:ListItem>
<asp:ListItem>5</asp:ListItem>
</asp:ListBox>
<a id="left">向左</a>
<a id="right">向右</a>
<asp:ListBox ID="ListBox2" runat="server" Width="100" Height="200">
</asp:ListBox>
</form>
</body>

jquery ListBox 左右移动的更多相关文章

  1. [转]jQuery ListBox Plugin(ListBox插件)

    本文转自:http://www.cnblogs.com/think8848/archive/2011/09/28/2193990.html 转载请注明作者(think8848)和出处(http://t ...

  2. jquery 双向select控件bootstrap Dual listbox

    http://www.cnblogs.com/hangwei/p/5040866.html       -->jquery 双向select控件bootstrap Dual listboxhtt ...

  3. jquery 点击按钮实现listbox的显示与隐藏,点击其他地方按钮外的地方,隐藏listbox

    本来不知道如何获取服务器的控件的,这下知道可以这么做了,所以记录下来.... <asp:ImageButton ID="alltime" ImageUrl="ima ...

  4. 利用JQuery 来操作 ListBox和ListBox内移动

    [导读]利用jquery 来操作 listbox和listbox内移动function listbox_move(listfrom,listto) { var size = $(" &quo ...

  5. Jquery双向select控件Bootstrap Dual Listbox

    效果预览: 一. 下载插件 github地址:https://github.com/istvan-ujjmeszaros/bootstrap-duallistbox 也可以在这个网站中下载:http: ...

  6. 基于JQUERY写的 LISTBOX 选择器

    本文来之于:http://blog.csdn.net/jetsteven/article/details/5104380# 1.经常用到如下图的选择器,而且要支持排序的,所以萌生用JQUERY写一个. ...

  7. jquery+ajax 实现text框模糊搜索并可利用listbox实时显示模糊搜索列表结果

    功能描述: text框中输入,text框下面的listbox中实时显示依据输入的内容进行模糊搜索的结果 js代码 $j(function() { $j("input[id='txtCos'] ...

  8. jquery 操作listbox 左右相互选择

    实现左右两个listbox的相互选择功能 代码如下: function ListBox_Move(listfrom, listto) { var size = $j("#" + l ...

  9. jquery.validate.js表单验证

    一.用前必备官方网站:http://bassistance.de/jquery-plugins/jquery-plugin-validation/ API: http://jquery.bassist ...

随机推荐

  1. ABAP 日期时间函数(转)

    转自:http://www.sapjx.com/abap-datetime-function.html 函数名称 (内页-点击名称可查看操作) 函数说明 备注 FIMA_DATE_CREATE RP_ ...

  2. 实例源码--Android软件更新模块

    下载源码   技术要点: (1) 通过网络检测服务器版本与本地版本 (2) 通过服务器下载最新版本 (3) 自动覆盖安装本地版本 详细介绍: 主要源码实现如下:  

  3. Helpers\Request

    Helpers\Request The Helpers\Request class is used for detecting the type of request and retrieving t ...

  4. Starship Troopers

    Problem Description You, the leader of Starship Troopers, are sent to destroy a base of the bugs. Th ...

  5. Lifting the Stone

    我们需要把一块石头平稳的从地板上拿起来.石头的底面是多边形且各个部分的高度都一样,我们需要找出石头的重心. input 测试案例  T; 每组第一行给出N,表示定点数. 接下来N行,每行连个数,表示坐 ...

  6. Peter's Hobby

    Problem Description Recently, Peter likes to measure the humidity of leaves. He recorded a leaf humi ...

  7. Lastest Version Carprog Full V7.28 update and EEPROM reading

    Carprog Full has recently launched the newest V7.28 (with all software activated and all 21items Ada ...

  8. JavaScript开发之路01(初识Sencha Touch框架)

    一.SenchaTouch的hello world实例: Ext.application({ name:'myapp', icon:'images/icon.png', glossOnIcon:fal ...

  9. python(2)-字符串(2)

    字符串格式化: 前面说过一种字符串格式化方法,来复习一下: >>> print('His name is %s', 'jeff') His name is %s jeff 其实格式化 ...

  10. hdu 1892 树状数组

    思路:就是一个很普通的二维树状数组,注意的是x1,y1不一定在x2,y2的左下方. #include<iostream> #include<cstring> #include& ...