[英]navigate back to same page on select-dropdown selection without clearing down controls?
I have a text box and a drop-down selection on a page, plus a bunch of urls. 我在页面上有一个文本框和一个下拉选择,外加一堆网址。
Clicking on the urls navigate back to the page with an updated url (for asp.net MVC2 functionality). 单击URL导航到具有更新URL的页面(用于asp.net MVC2功能)。 This does not cause the texbox to clear down.
这不会导致texbox消失。
On my dropdown "onchanged" event I call window.location = url;
在下拉菜单“ onchanged”事件中,我调用
window.location = url;
(with url being the pages url with a sortOrder in the query string)... but this causes the pages text-box text to clear down. (其中url是查询字符串中带有sortOrder的页面url)...但这会导致页面文本框文本被清除。
Is there any way I can get the drop-down to postback to the page on selection changed and NOT clear down the text box? 有什么方法可以使下拉菜单更改后回发到页面,而不清除文本框?
Cheers, 干杯,
James. 詹姆士。
What do you mean with "clear down"? “清除”是什么意思? Does the dropdown lose it's selected item (eg gets reset to a default value)?
下拉菜单会丢失其所选项目吗(例如,重置为默认值)?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.