jsonp

Injecting JQuery Cross-Domain

Hello, Is it safe to inject JQuery's script using JsonP? The installation of my web application is - adding a script to a customer's website (like google analytics). I was thinking of using JQuery on the customer's website, as part of my own injected script. I was wondering, if there is some kind of risk? The application needs to supp...

MooTools JSONP request not works with invalid password

I make a JSONP request using MooTools: var username = 'hsz'; var password = 'pass'; var req = new Request.JSONP({ url: 'http://api.blip.pl/profile.json', method: 'get', headers: { 'Authorization' : 'Basic ' + Base64.encode(username + ':' + password), 'Accept' : 'application/json', 'Content-Type...

Please explain JSONP

I don't understand jsonp. I understand JSON. I don't understand JSONP. Wikipedia is the top search result for JSONP. It says JSONP or "JSON with padding" is a JSON extension wherein a prefix is specified as an input argument of the call itself. Huh? What call? That doesn't make any sense to me. JSON is a data format. There's no ca...

I need help with json jquery, I'm totally n00b

Hi all, using firebug on a site and I noticed this json post request: POST /xxxx/yyy Host test.it User-Agent Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.5) Gecko/20091102 Firefox/3.5.5 Accept text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8,application/json Accept-Language en-us,en;q=0.5 Accept-Encoding gzip,deflate ...

C# WCF works inside corporate firewall but not outside...

I am running into an “interesting” error with my WCF JSONP web service. It is the only one I have and it only exposes one method. If I hit my service via web browser internally it pops up with a message that, effectively, MEX is not enabled (true). If I hit it from outside our network (like you would unless you were on a machine in my...

JSONP PHP Session does not remain constant

Hello, Using JSONP on a site say xyz.com, I am calling a site abc.com/test.php. However, everytime I call this site, I get a new session id in IE6 and IE7. In other browsers it remains constant. The code of test.php is something like: <?php session_start(); echo session_id(); ?> However, after I visit http://abc.com/test.php in anot...

jsonp -> json_decode()

for some reason I can't get the information out of a returned jsonp string, <?php // Created by Talisman 01/2010 ★✩ $vorto = $_GET['vorto']; // Get the Word from Outer Space and Search for it! if (isset($vorto)) { echo $vorto; } else { $Help = "No Vorto -> add ?vorto=TheWordYouWant to the end of this website"; echo $Help; } ...

Cross Domain ajax and php sessions

I'm baffled by this one... I'm doing a remote widgety type of setup, we'll control both domains so security is not a concern. I'm using jsonp to allow cross domain ajax requests. The visited site is domain1.com, which inclues: <script src="domain2.com/file.js"></script> file.js uses jQuery to make ajax requests: $.ajax({ url: 'ht...

Online JSONP converter/wrapper

I would like to fetch a source of file and wrap it within JSONP. For example, I have pets.txt. I want to retrieve source of that file from another domain using nothing but client-side JavaScript. Can I do it? Actually, I can't. I can do it only for JSONP. So, I can convert pets.txt to JSONP. I'm looking for online service which can co...

Cross-domain AJAX using jsonp and .NET Web Service over SSL/HTTPS

Hello, I am using the example below to do a cross-domain ajax call using .net web services and jquery. http://bloggingabout.net/blogs/adelkhalil/archive/2009/08/14/cross-domain-jsonp-with-jquery-call-step-by-step-guide.aspx It works fine until I try to change my endpoint to https. I don't get any errors, just no response. My first qu...

String to JSON object.

Hi, I am using a JSON object to create graphs with Google visualization. I am trying to design the data source. For this i am creating a JSON object on my browser. var JSONObject = { cols: [{id: 'date', label: 'Date', type: 'date'}, {id: 'soldpencils', label: 'Sold Pencils', type: 'number'}, {id: 'soldpens', label: 'Sold ...

Configurationless WCF using Factories and JSONP

I'm using the WebServiceHostFactory in my WCF services to avoid having to create a crapton of binding configuration in web.config. However, I'd like to expose the services as XML/JSON and JSONP. Reading: http://jasonkelly.net/archive/2009/02/24/using-jquery-amp-jsonp-for-cross-domain-ajax-with-wcf-services.aspx It does not look like I...

ASP.NET MVC OutputCache JSONP

I cache everything that is possible on an ASP.NET MVC website and it works perfect. Now I have created an API where the calls go to Controller Actions. (http://mysite.com/topics/latest.json) The API is able to return results in different formats (json, xml, rss). The data for returning is loaded in the Action: [ResponseFilter] public ...

JSONP request to stackoverflow with mootools not working

I'm trying to build a custom stackoverflow badge using JSONP and mootools. Here is the code: new Request.JSONP('http://stackoverflow.com/users/flair/166325.json', { onComplete: function(data) { console.log(data); } }).request(); However, I always get back this message: RequestJSONPrequest_maprequest_0 is not defined I'm won...

Problem with jQuery and $.ajax when trying to parse JSONP

So, here's my JSONP URL: http://community.tradeking.com/leaderboard.js And here's the jQuery I'm trying to parse it with: $.ajax({ dataType: 'jsonp', jsonp: 'callback', url: 'http://community.tradeking.com/leaderboard.js?callback=?', success: function () { alert("something"); }, }); And here's the error I'm getting in ...

jQuery plugin "lazy" fails to load two jQuery plugins with $.getJSON calls in each of them: too much recursion ONLY in Firefox

Plugin: jQuery lazy() I ask here because the project page itself seems to be dead. What steps will reproduce the problem? 1. embed two jQuery-Plugins that are both using the $.getJSON function results in a "too much recursion error" in firefox. If the same scripts are referenced with lazy it works fine. Problem only persits in firefox...

Jquery success function not firing using JSONP

Hi All, Been doing some playing call my service which is on a different domain using jQuery. The call to the service is successfully made (my debug point gets tripped), and the correct response is returned (I sniff the traffic). My problem is mainly that the success and failure callbacks don't get fired. I have read some other posts ...

jQuery + JSONP return data empty?

Hi - I need to access data on a subdomain I've been trying to use JSONP which jQuery has support for. The data that I'm accessing on the subdomain is a static (regenerated) .json file (http://www.example.com/data.json) I was running into "Invalid Label Error" errors and realized the data needed to be wrapped in parenthesis and use ?ca...

Why isn't jQuery automatically appending the JSONP callback?

The $.getJSON() documentation states: If the specified URL is on a remote server, the request is treated as JSONP instead. See the discussion of the jsonp data type in $.ajax() for more details. The $.ajax() documentation for the jsonp data type states (emphasis mine): Loads in a JSON block using JSONP. Will add an extra "?call...

JSONP request using jquery $.getJSON not working on well formed JSON.

I'm not sure is it possible now from the url I am trying. Please see this url: http://www.heiaheia.com/voimakaksikko/stats.json It always serves the same padding function "voimakaksikkoStats". It is well formed JSON, but I have not been able to load it from remote server. Does it need some work from the server side or can it be loaded w...