getjson

Problems with jQuery load and getJSON only when using Chrome

I'm having an issue with two jQuery calls. The first is a "load" that retrieves HTML and displays it on the page (it does include some Javascript and CSS in the code that is returned). The second is a "getJSON" that returns JSON - the JSON returned is valid. Everything works fine in every other browser I've tried - except Chrome for e...

jQuery .getJSON() Not Parsing All Objects

I'm using jQuery's .getJSON function to parse a set of search results from a Google Search Appliance. The search appliance has an xslt stylesheet that returns the results as JSON data, which I validated with both JSONLint and Curious Concept's JSON Formatter. According to FireBug, the full result set is returned from the XMLHTTPRequest,...

getJSON for dropbox data

Although i used getJSON in http://jsbin.com/dbJSON/edit i have not been able to connect with any of my own made up data. i tried 4, and the example at Flickr for "cats". Only the latter worked... this is the output: {assoc: null,assoc.js: null,stub: null,stub.js: null,cat: [object Object]} i am at that "base", as i did get the im...

getjson and servers

Is getJSON only useful for those who control a server? Is there any other alternative for getting data from a file? i tried $.getJSON("good.json", function(data){ out=out+"good.json: "+data + ","; }); where good.json = {"a":"1","b":"2"} and got a result of 'null' for data. These all are valid JSON files, and all give null ...

How can I use a RESTful JSONResult from my controller to populate Bing Maps Geocoding?

I know there are a few topics on this, but I seem to be fumbling my way through with no results. I'm trying to use a controller to return JSON results to my Bing Maps functions. Here's what I have for my controller (yes it is properly returning JSON data. Function Regions() As JsonResult Dim rj As New List(Of RtnJson)() rj.Add...

setting jQuery .data() within .getJSON callback

I'm doing a couple of .getJSON calls and if any one of them succeeds, I'm trying to set a bool to true so I can then do some other stuff elsewhere on the page. I was trying to use jquery's .data() function, but I don't seem able to set it from inside the .getJSON callback. for example: $('#citations_button').data('citations', false); ...

Jquery getJSON Not Working Cross Site

I have a piece of javascript that grabs JSON data. When executed locally everything seems to work fine. However, when I try accessing it from a different site, it doesn't work. Here's the script. $(function(){ var aT = new AjaxTest(); aT.getJson(); }); var AjaxTest = function() { this.ajaxUrl = "http://mydeveloperpage.com...

jQuery getJSON problem when request is not returned as JSON

I have the following code jQuery.getJSON(encodeURI(strUrl), {address:address,state:state, zip:zip},function(data){ alert('HELLO World!'); }); If for some reason the strUrl returns a string that's not in JSON format the callback function never gets called. Is there a way to know if the response is in json format or if something we...

generate and view the dynamically created pdf using iTextSharp in c# using MVC framework

is it possible to generate the pdf dynamically using iTextSharp and view it in a new window through a Json call? ...

.getJSON() returns null

I'm using jQuery to get and parse JSON using example flickr service : http://api.jquery.com/jQuery.getJSON/ everything works fine if i use flickr url , the problem starts when i try to get my own service. It works when I save the output and read it from file but i doesn't work from the server url. Firebug shows two that the object is n...

Jquery Ajax image load works only after alert statement is inserted in $(window).one function

Hello, I have a peculiar problem. I am loading a JSON file that contains the src, width and height of a number of images. I am trying to load them into the smooth script jquery plugin and have the images scroll automatically. The "viewing area" div can fit three images side by side. When I first load the page, only the first image is ...

jQuery getJSON() - how to pass request headers?

Original Question I need to do a getJSON() request, but how do i pass authorisation and custom headers? New Question I am getting issues that by using your example that the request header are taking the name, but NOT the values and that the URL is being shown through a manual request in fiddler to being inserted in as options instead ...

$.getJSON for progress bar NOT working in Safari and Chrome (but OK in IE6+ and FF)

Hi folks This one's perhaps a little long-winded, but it's really baffling me and a couple of other people. We've got a progress bar that's updated during file uploads. The JS is here (too much to paste into this body). Basically, the form submit event starts a timer loop which, every 2 secs, fires a $.getJSON() call to the server to ...

NodeJS won't return data to jQuery.getJSON

I've set up NodeJS and it's returning data when I browse to the URL: http://184.106.206.235 However, when I try to call that URL using $.getJSON, the callback shows "null" for the "data" variable and "success" for the "textStatus" variable. I imagine this could be a cross-domain thing, but I'm surprised that the textStatus says "succe...

I have a svg image working fine in IE but does not work in firefox, safari and chrome

Hi All, I have create an svg image and mapped it in through javascript the image works from a database through an api call using the $.ajax() function, this works fine in internet explorer after clicking yes on the security risk box. For more information on what i am calling for the API call here is the previous post that shows the cal...

How do I set the correct json headers?

Is there a way in htaccess to ensure the headers for my json are correct? Update: Does anyone see anything wrong with these headers for json? Date Mon, 26 Jul 2010 08:31:11 GMT Server Apache/2.2.15 (Unix) mod_ssl/2.2.15 OpenSSL/0.9.7a mod_fcgid/2.3.5 Phusion_Passenger/2.2.15 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0....

getJSON function always returns null

Hello all I am trying to make a get http request using jquery getJSON function. I have implemented it like this... <script type="text/javascript"> $(function(){ $("#query").keyup(function(event) { keyword = $("#query").val(); $.getJSON("http://api.flickr.com/services/feeds/photos_public.gne?tags=cat&amp;tagmode=any&amp;...

$.getJSON fails with parse error

Hi, I'm trying to use jQuery.getJSON to get data from a domain I don't own myself. I've made it work in the past, but this time it keeps failing. I get the response into the browser, but then Chrome says SyntaxError: Unexpected token : and Firefox says invalid label. There are a few peculiarities with this. Say the code is MY_JSON_RESP...

getJSON returning null phonegap(android)

Hi folks, i am developing phone-gap app in android. In app I am calling a servlet returning JSON. Under app code I am calling following method through javascript in index.html JQuery.getJSON(servleturl,function(data){alert(data)}); When running in emulator the alert is getting displayed, but data is always null. However if i launch t...

jquery / jqtouch getJSON call causing infinite loop?

Writing my first JQTouch app. When I go from #login to #home, a JSON ajax call happens successfully but the pageAnimationEnded event appears to be in an infinite loop. $(function(){ $('#login').ajaxComplete(function (e, xhr, settings) { jQT.goTo('#home', 'flip'); }); ...