我需要在ASP页面中传递一个带有AJAX的数组。
我尝试将它作为GET传递,以查看它发送的数据,并注意到ASP只接收数组的最后一条记录。
如何发送和接收整个数组?(最好采用POST法)
Javascript
function editar(i) {
arr=[];
j=0;
for (n=2; n<=9; n++) {
arr[j]=$("#"+i+"-"+n).val(); //saves in the array all the field of a table's row
}
$.aja
我以前使用Controller而不是ApiController,今天我尝试使用ApiController,并发现了下面的问题。
ASP.NET Core操作参数无法接收axios application/json post传递数据
asp.net核心api代码
[ApiController]
[Route("[controller]")]
public class TestController : ControllerBase
{
[HttpPost]
public async Task<IActionResult> Post(string json
我正在尝试执行jQuery post将文本编辑器的内容从我的javascript.The asp.net页面发送到asp.net页面(asp.net 4.0)将接收到该内容并将其保存到数据库。我将文本编辑器的内容追加到querystring.When中内容很大,出现以下异常
The length of the query string for this request exceeds the configured maxQueryStringLength value.
它适用于小的content.But当内容很大时,它会抛出一个错误
下面是我的javascript代码
var conten
我使用数组来存储问题标签,但是当我发布来自Chrome的数据时,我不会在TagId阵列上接收任何数据。其他属性没有问题,我收到了onlu,TagId is null,这是我的代码:
Question.cs
public partial class Question
{
[Key]
public int Id { get; set; }
...
[Display(Name = "Tags")]
[NotMapped]
public int[] TagId
{
get
{
S