【发布时间】:2013-06-09 10:37:27
【问题描述】:
我在 MVC 中的 IIS 7 中的 ajax 调用有问题,我像这样使用 jquery ajax:
$.ajax({
url: '@Url.Action("IsLoanNumberValid", "File")',
type: 'Post',
cache: false,
data: {
fileCategoryId: ddlFileCategory.value(),
loanNumber: $("#txtLoanNumber").val(),
}
.....}
我在开发应用程序时没有任何问题,但是当我发布mvc应用程序并在iis post方法中上传时出现问题并且不返回结果,
这是萤火虫设计时的请求
这是应用程序在 iis7 中时的请求
所有的ajax post方法都不能返回结果
Kendo 网格调用的 FilterFiles_Read 方法在 post 方法中也有问题! 网格通过这行代码绑定:.Read(read => read.Action("FilterFiles_Read","File")
这是它的代码
@(Html.Kendo().Grid<CommonData.Domain.File>()
.Name("Grid")
.Pageable()
.EnableCustomBinding(true)
.Columns(columns =>
{
columns.Bound(e => e.FileCategory.Title);
columns.Bound(e => e.BankFileNo);
})
.DataSource(dataSource => dataSource
.Ajax()
.Model(model => model.Id(o => o.Id))
.Read(read => read.Action("FilterFiles_Read","File").Data("GetValues"))
.PageSize(10)
.Total(TempData["Total"] == null ? 0 : (int)TempData["Total"])
)
)
我必须配置 iis 还是必须更改应用程序?请帮帮我
【问题讨论】:
-
你在FF以外的浏览器中测试过吗?
-
是的,所有的都有这个问题“指定的网络名称不再可用”
标签: asp.net-mvc jquery iis-7 http-post kendo-grid