Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/jquery-ui/2.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
jquery ui在ajaxenabled false之后不工作_Jquery_Jquery Ui_Razor_Jquery Mobile Ajax - Fatal编程技术网

jquery ui在ajaxenabled false之后不工作

jquery ui在ajaxenabled false之后不工作,jquery,jquery-ui,razor,jquery-mobile-ajax,Jquery,Jquery Ui,Razor,Jquery Mobile Ajax,使用以下命令将ajaxenabled设置为false后: <script type="text/javascript"> $(document).bind("mobileinit", function () { $.mobile.ajaxEnabled = true; }); </script> $(文档).bind(“mobileinit”,函数(){ $.mobile.ajaxEnab

使用以下命令将ajaxenabled设置为false后:

<script type="text/javascript">
            $(document).bind("mobileinit", function () {
                $.mobile.ajaxEnabled = true;
            });
</script>

$(文档).bind(“mobileinit”,函数(){
$.mobile.ajaxEnabled=true;
});
我的可选表格不工作

$('#usersListTable').selectable({ filter: 'tbody tr' });
    $('td').click(function () {
        row_index = $.trim($(this).parent().find(".username").html());
    });

<table id="usersListTable" class="list">
 <thead>
    <tr>               
        <th>
            @Html.DisplayNameFor(model => model.Loginname)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.Email)
        </th>        
        <th>
            @Html.DisplayNameFor(model => model.IsAdministrator)
        </th> 
    </tr>
 </thead>
 <tbody>
@foreach (var item in Model)
{
    <tr>                     
        <td class="username">
            @Html.DisplayFor(modelItem => item.UserName)
        </td>
        <td>
            @Html.DisplayFor(modelItem => item.Email)
        </td>        
        <td class="centeredtd">
        @GlobalHelpers.Checkbox(item.IsAdministrator)           
        </td> 
    </tr>
}
<tbody>
</table>
$('#usersListTable')。可选({filter:'tbody tr'});
$('td')。单击(函数(){
行索引=$.trim($(this.parent().find(“.username”).html());
});
@DisplayNameFor(model=>model.Loginname)
@DisplayNameFor(model=>model.Email)
@DisplayNameFor(model=>model.IsAdministrator)
@foreach(模型中的var项目)
{
@DisplayFor(modelItem=>item.UserName)
@DisplayFor(modelItem=>item.Email)
@GlobalHelpers.Checkbox(item.IsAdministrator)
}
但是,一旦我将ajaxenabled设置为true,它就会开始工作,有没有办法让它与ajaxenabled false一起工作?
谢谢大家!

在谷歌搜索了几个小时后,我发现:

我已经把我的剧本:

$('#usersListTable').selectable({ filter: 'tbody tr' });
    $('td').click(function () {
        row_index = $.trim($(this).parent().find(".username").html());
    });
里面

$(document).on('pageinit', function(){

});