Hello
If you use a callbackKey of ‘callback’ it seems to work.

See:
https://api.instagram.com/v1/media/popular?access_token=&client_id=95e09e6147344028bfb8972ce0f3a0b0&count=10&callback=Request.JSONP.request_map.request_0
 
<https://api.instagram.com/v1/media/popular?access_token=&client_id=95e09e6147344028bfb8972ce0f3a0b0&count=10&callback=Request.JSONP.request_map.request_0>

Ryan




> On 16 Sep 2015, at 14:17, arian <[email protected]> wrote:
> 
> It seems the instragram API doesn't work this way for JSONP.
> 
> As you can see, the URL  
> <https://api.instagram.com/v1/media/popular?access_token=&client_id=95e09e6147344028bfb8972ce0f3a0b0&count=10&jsoncallback=Request.JSONP.request_map.request_0>https://api.instagram.com/v1/media/popular?access_token=&client_id=95e09e6147344028bfb8972ce0f3a0b0&count=10&jsoncallback=Request.JSONP.request_map.request_0
>  
> <https://api.instagram.com/v1/media/popular?access_token=&client_id=95e09e6147344028bfb8972ce0f3a0b0&count=10&jsoncallback=Request.JSONP.request_map.request_0>
>  contains only JSON.
> 
> If it would support JSONP, the result would be: 
> Request.JSONP.request_map.request_0({"some": "JSON here"})
> 
> 
> On Wed, Sep 16, 2015 at 3:13 PM Adrian Statescu <[email protected] 
> <mailto:[email protected]>> wrote:
>           var myJSONP = new Request.JSONP({
> 
>                        url: ' 
> <https://api.instagram.com/v1/media/popular?access_token=&client_id=95e09e6147344028bfb8972ce0f3a0b0&count=10>https://api.instagram.com/v1/media/popular?access_token=&client_id=95e09e6147344028bfb8972ce0f3a0b0&count=10
>  
> <https://api.instagram.com/v1/media/popular?access_token=&client_id=95e09e6147344028bfb8972ce0f3a0b0&count=10>',
> 
>                        callbackKey: 'jsoncallback',
> 
>                        onRequest: function( url ){
> 
>                                   console.log( url ) 
>                        },
> 
>                        onSuccess: function( response ){
> 
>                                   console.log( response )
>                        }
>                        }).send();
> 
> I've got the following message in console.log "SyntaxError: missing ; before 
> statement". something is wrong in this class.Any idea? Thanks
> -- 
> 
> --- 
> You received this message because you are subscribed to the Google Groups 
> "MooTools Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to  
> <mailto:[email protected]>[email protected]
>  <mailto:[email protected]>.
> For more options, visit  
> <https://groups.google.com/d/optout>https://groups.google.com/d/optout 
> <https://groups.google.com/d/optout>.
> 
> -- 
> 
> --- 
> You received this message because you are subscribed to the Google Groups 
> "MooTools Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected] 
> <mailto:[email protected]>.
> For more options, visit https://groups.google.com/d/optout 
> <https://groups.google.com/d/optout>.

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"MooTools Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to