Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/459.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 设置selectedIndex不';t更改jQuery移动下拉列表_Javascript_Jquery Mobile - Fatal编程技术网

Javascript 设置selectedIndex不';t更改jQuery移动下拉列表

Javascript 设置selectedIndex不';t更改jQuery移动下拉列表,javascript,jquery-mobile,Javascript,Jquery Mobile,我有一个jQuery移动控件,但何时执行以下操作: $('#mySelector')[0].selectedIndex = 3 底层选择器会更新(我可以检查selectedIndex值,它是正确的),但可见的jQuery mobile“pretty”版本不会更新。我在文档中找不到以编程方式设置值的位置。有没有办法做到这一点?$(“#mySelector”)[0]后接$(“#mySelector”)。选择菜单(“刷新”)。谢谢,就是这样,除了其他一些诡计,比如网站显然只为某些用户使用jQuery

我有一个jQuery移动控件,但何时执行以下操作:

$('#mySelector')[0].selectedIndex = 3

底层选择器会更新(我可以检查selectedIndex值,它是正确的),但可见的jQuery mobile“pretty”版本不会更新。我在文档中找不到以编程方式设置值的位置。有没有办法做到这一点?

$(“#mySelector”)[0]
后接
$(“#mySelector”)。选择菜单(“刷新”)。谢谢,就是这样,除了其他一些诡计,比如网站显然只为某些用户使用jQuery mobile。如果你加上它作为答案,我会接受的。