Forums

Posting in these forums is disabled. These forums will be available for archive purposes. Please join the new forums at the links below:

  • yui-support - replaces the `YUI 3.x` and `YUI 3 Gallery` forums.
    We have created the following discussion categories within this group to aid discoverability for these most-used topics:
    • Charts for YUI Charts support.
    • DataTable for YUI DataTable support.
    • Gallery for YUI Gallery support, including support for published Gallery components as well as the Gallery process in general.
    • Tools for support of YUI’s suite of developer tools such as selleck, shifter, grover, yogi, etc.
    • Everything Else for questions that don’t fit one of the categories above, we’ve got you covered here.
  • yui-deprecated - replaces the `YUI 2.x` forum and the forums of other deprecated products (`YUI Doc`, `Builder`, `YUI PHP Loader`, etc.).
  [ 2 posts ]
New Topic | Post Reply | Print view
Previous topic | Next topic

Itye Richter

  • Username: itye
  • Joined: Wed Apr 28, 2010 11:56 am
  • Posts: 2
  • GitHub: itye
  • Gists: itye
  • IRC: itye
  • Offline
  • Profile
Tags:
  • json
  • node
  • xml

JSONP and Yahoo! Pipes

Post Posted: Wed Apr 28, 2010 12:06 pm
+0-
Hi,
Thank you for this module, it is very useful.

I am trying to access a Yahoo! Pipe via JSONP, however the callback parameter is _callback=something. Notice the "_" before the callback.
How can I change the default call of JSONP module, which is using callback=something, to the one that Pipes requires?
Here is the code that I use:

Code:
YUI({
            modules: {
                'gallery-jsonp': {
                    fullpath: 'http://yui.yahooapis.com/gallery-2010.02.10-01/build/gallery-jsonp/gallery-jsonp-min.js',
                    requires: ['get', 'oop'],
                    optional: [],
                    supersedes: []
                }

            }
        }).use('gallery-jsonp', 'node', function(Y) {
            rss = 'http://www.engadget.com/rss.xml';
            var url = 'http://pipes.yahoo.com/pipes/pipe.run?_id=gH84AH3M2xGUtbMFdbq02Q&_render=json&rssUrl=' + encodeURIComponent(rss) + '&callback={callback}';
            Y.jsonp(url, function(jsonObj) {
                Console.log(jsonObj);
            });
        });


Thanks!
Itye.

Itye Richter

  • Username: itye
  • Joined: Wed Apr 28, 2010 11:56 am
  • Posts: 2
  • GitHub: itye
  • Gists: itye
  • IRC: itye
  • Offline
  • Profile

Re: JSONP and Yahoo! Pipes

Post Posted: Wed Apr 28, 2010 12:52 pm
+0-
I figured it out.
I used :
Code:
Y.JSONPRequest._template = "_callback={callback}";


to override the original template.

Thanks again!
Itye.
  [ 2 posts ]
New Topic | Post Reply | Print view
Previous topic | Next topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum