[RESOLVED]How to post data from partial view to diffrent controlller and validate model in Controller.

How to post data from partial view to diffrent controlller and validate model in Controller.

Use

<form 

tag.

http://www.w3schools.com/tags/tag_form.asp

I already use one form tag for main view.

if i am using nested form tag then it was point to main form tag action.

so How to post back data to server from partial view ?

try using jquery

  $.ajax({
            type: 'POST',
            url: url,
            data: $('#' + form).serialize(),
            dataType: "html",
            success: function(){},
            error: function(){}
        });

Leave a Reply