P
p3ktiff
Hi All,
I've have been searching the net for almost a week but i can't find what
im looking for.
I need help on my particular problem.
I have a model that is inherited by a viewpage.
ex.
<%@ Page Language="C#" MasterPageFile="~/Views/Shared/Site.Master"
Inherits="System.Web.Mvc.ViewPage<myproject.person>" %>
In my view,I have a html form & fieldset which is mapped to the model,
base on the id's of html control's
My problem is, i used jquery when the submit button is clicked and i
don't know how to pass the model data in my controller's action method
parameter in java script
function postUpdate() {
var feedsPanel = $("#feedsPanel");
var name = $("#name").val();
var address = $("#address").val();
$.post("/Home/Index", { !!! i dont know what to put here
!!!! }, function(data) { feedsPanel.html(data); });
});
in my home controller
public actionresult Index(Person obj) {
.................
}
Please if someone has a solution for this..
thanks
I've have been searching the net for almost a week but i can't find what
im looking for.
I need help on my particular problem.
I have a model that is inherited by a viewpage.
ex.
<%@ Page Language="C#" MasterPageFile="~/Views/Shared/Site.Master"
Inherits="System.Web.Mvc.ViewPage<myproject.person>" %>
In my view,I have a html form & fieldset which is mapped to the model,
base on the id's of html control's
My problem is, i used jquery when the submit button is clicked and i
don't know how to pass the model data in my controller's action method
parameter in java script
function postUpdate() {
var feedsPanel = $("#feedsPanel");
var name = $("#name").val();
var address = $("#address").val();
$.post("/Home/Index", { !!! i dont know what to put here
!!!! }, function(data) { feedsPanel.html(data); });
});
in my home controller
public actionresult Index(Person obj) {
.................
}
Please if someone has a solution for this..
thanks