I am trying to do a jQuery AJAX call on a ASP.Net MVC page. I can step through the call back function in my debugger and see that the javascript is executing, but the does not update.
<asp:Content ID="Content2" ContentPlaceHolderID="MenuContent" runat="server">
<% Html.RenderPartial("homeMenu"); %>
<script type="text/javascript">
InitHomeMenu('homeMenu', function (menuItem) {
var id = menuItem.attr('id');
if (id = 'menuMission') {
$('homeContent').load('Home/Mission');
}
else if (id = 'menuSuggestions') {
$('homeContent').load('Home/Suggestions');
}
});
</script>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
<div id="homeContent">
<% string control = ViewData["Control"] != null ? ViewData["Control"].ToString() : "Mission";
Html.RenderPartial(control); %>
</div>
</asp:Content>
The call to $('homeContent').load() is working. I can confirm I have data, but the div does not update.