Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8833685
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T08:50:22+00:00 2026-06-14T08:50:22+00:00

Today, I wrote my very first ASP MVC WebService (.Net version 4, Entity4.2). It’s

  • 0

Today, I wrote my very first ASP MVC WebService (.Net version 4, Entity4.2). It’s really simple and just returns back an array of custom ItemChoice objects. When I call it directly from IE, it wants to download the json objects, and when I call it from FF, I see the XML version of the objects.

I’m working on integrating the web service into a page I’m building on localhost (to start), using the jquery 1.7.1 that ships with VS 12.

What happens when I call the service from JQuery is that the success function never runs. However, if I point getJSON to the local copy of the same service, it works. Looking at Charles Web Proxy, both come back and appear to have identical returns.

The code looks like this:

<script type="text/javascript">
    $(document).ready(function() {
        $.getJSON('http://myserver/CECService/api/itemchoices',
            function (data, status) {
                $.each(data, function(key, val) {
                    $('<option />', {value:val.itemValue, text:val.displayText}).appendTo('#School');

                });//end each
            });//end get json
    });//end document.ready
</script>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T08:50:23+00:00Added an answer on June 14, 2026 at 8:50 am

    You’re experiencing this issue, because you are making an ajax call which violates the browser’s same origin security policy. See the following for an explanation of potential a work around.

    EDIT:

    Another often used approach is JSONP.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I wrote my first program in Haskell today. It compiles and runs successfully .
Well, today I ran into an oddity. I wrote my own version of GetProcAddress
today i hit a really annoing problem with wpf. i just want to align
we had a programing lesson today. Very easy exercise in console. I wrote a
I wrote a very simple C# application to send Tweets between to Windows machines.
I'm new in PHP and my question is REALLY basic today. I wrote the
Today is my first day learning java :) I'm having problems running a very
I started to learn about Mockito only today. I wrote some simple test (with
Disclaimer: The program I wrote works. I just need help understanding it. Today I
I am very new (started today) to writing chrome extensions but need to write

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.