3
votes
2answers
3k views

ASP.NET MVC Partial view ajax post?

Index.html (View) <div class="categories_content_container"> @Html.Action("_AddCategory", "Categories") </div> _AddCategory.cshtml (PartialView) <script> ...
4
votes
2answers
705 views

ASP.NET Web API Authentication Options

What options are available for authentication of an MVC3 Web API application that is to be consumed by a JQuery app from another domain? Here are the constraints/things I've tried so far:- I don't ...
3
votes
3answers
2k views

jQuery unobtrusive validation ignores “cancel” class on submit button if used in Ajax form

I am trying to implement optional client side validation using ASP.NET MVC 4, unobtrusive jQuery validation, unobtrusive ajax This works fine Following pictures show what I mean with optional ...
2
votes
4answers
5k views

Sending JSON object to Web API

I am trying to figure out how I can send some information from a form to a Web API action. This is the jQuery/AJAX I'm trying to use: var source = { 'ID': 0, 'ProductID': ...
13
votes
3answers
5k views

WebAPI Controller is not being reached on DELETE command

I am having difficulty getting the DELETE Method on my Controller to fire when submitting the request over ASP.NET Web API. It returns a 404 but I cannot figure out why. The GET & POST requests ...
4
votes
1answer
11k views

Error :Request header field Content-Type is not allowed by Access-Control-Allow-Headers

I created an mvc4 web api project using vS2012. I used following tutorial to solve the Cross-Origin Resource Sharing, ...
1
vote
1answer
464 views

How to retain an injected partial view after page refresh in asp.net mvc

I am using ASP.NET MVC 4 and jQuery. I have a button control on my view. When it is clicked it "injects" a partial view into my view. When I refresh the page then the partial view is gone. My HTML ...
1
vote
1answer
770 views

How to properly render the return of AJAX POST MVC 4

I'm using MVC 4 and I am trying to send a post request and I am getting a successful return from my controller with the resulting view in HTML form, but I'm not sure what to do with it at that point. ...
1
vote
2answers
160 views

Using unobtrusive JavaScript, parameter isn't null, but its values are

This was working when my JavaScript was in the same page as my cshtml file: function SaveEntity() { // more code here alert(entity.FirstName); // this shows that entity's properties have ...
1
vote
1answer
152 views

JSONP Callback, response data is null

Following on from my original question: Not receiving JSONP callback I am now trying to process the information in the JSONP callback and I cannot seem to get any data to "load" i.e. the rsp object ...
1
vote
2answers
351 views

Hide current element and show the next one

I'm creating a ASP.NET application where shows you a quiz. This quiz should be show to the user displaying question by question. I mean, appears the first question and when he press the button next, ...
0
votes
1answer
134 views

Jquery Accordion Validation Not working when rendering Partial View through $.ajax call

Hi friends,I am working on MVC 4 Razor and I am stuck in a situation where Employee Personal Details form is to be filled in steps(wizard)..for which i used jquery accordion control..for every ...
0
votes
1answer
104 views

Not receiving JSONP callback

I am following the sample code/tutorial for ASP.NET MVC and JSONP blog post: http://blogorama.nerdworks.in/entry-EnablingJSONPcallsonASPNETMVC.aspx I have taken the code sample and have modified it ...
0
votes
0answers
4k views

Origin null is not allowed by Access-Control-Allow-Origin

I have created a mvc4 web api project using vS2012 for JQuery Mobile application(backend is mvc4 and frontend is pure html).I used the following tutorial to solve the Cross-Origin Resource Sharing, ...
0
votes
2answers
736 views

View not rendering MVC 4

I have a view which is not being called when I step through the code I see it get to the action in the controller and return the view but it does not load the view it just stays on the current page. ...