How can I refresh just a Partial View in its View?

前端 未结 3 695
北恋
北恋 2021-02-03 11:30

What Am I doing wrong guys? This is the idea...

Index view

@Html.Partial(\"PartialView\", Model)
3条回答
  •  情书的邮戳
    2021-02-03 12:07

    Well, I read the solution (Auto Refresh Partial View). I am posting it, hoping clarify the question:

    index.html

    @Html.Partial("PartialView", Model)
    
    

    PartialController

    public ActionResult PartialView()
    {
        // DO YOUR STUFF. 
        return PartialView("PartialView", model);
    }
    
    [HttpPost, ValidateInput(false)]
    public EmptyResult POSTPartialView(string param1)
    {
        // DO YOUR STUFF AFTER SUBMIT.
        return new EmptyResult();
    } 
    

提交回复
热议问题