Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $("#myForm").submit(function (event) {
- var data = $('#myForm').serialize();
- event.preventDefault();
- // check if the input is valid
- if (!$(this).valid()) return false
- $.ajax({
- url: '@Url.Action("MyAction", "Home")',
- type: 'POST',
- cache: false,
- data: data,
- success: function (result) {
- }
- }
- });
- });
- public ActionResult myAction(myModel model,HttpPostedFileBase File)
- {
- }
Add Comment
Please, Sign In to add comment