选择下拉列表时如何避免重新加载页面. [英] How to avoid reload the page when dropdown list selection.

查看:90
本文介绍了选择下拉列表时如何避免重新加载页面.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在我使用下拉列表的形式中,

我使用了两个下拉列表.
我需要从dropdownlist1中选择一个项目,然后其相应的一些详细信息
在dropdownlist2中显示.
我通过设置Autopost back = True来实现它.
但是,当我选择一个选项时,页面将重新加载,因此非常慢.
如何避免此问题.

解决方案

vipinsethumadhavan写道:

但是当我选择一个选项,页面将重新加载,因此非常慢.



使用Ajax怎么办?


u必须为此使用AJAX做部分更新.


In a form I used dropdownlist ,

I used a two dropdownlist.
I need to select an item from dropdownlist1, then its corresponding some details
show in dropdownlist2.
I implemented it by set Autopost back=True.
But when I select an option the page will reload, so it is very slow.
How to avoid this problem.

解决方案

vipinsethumadhavan wrote:

But when I select an option the page will reload, so it is very slow.



What about using Ajax?


u have to do the partial updating for this use AJAX. already one person has given awnser.


You can use JQuery and Json with Webservice to populate another dropdownlist on the base of selected value in the first dropdownlist.


这篇关于选择下拉列表时如何避免重新加载页面.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆