• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
Locked
0

Does BC Support JSONP

Engaged ,
Nov 25, 2014 Nov 25, 2014

Copy link to clipboard

Copied

I want to use BC to generate some JSON data that will be retrieved by a 3rd party app outside of the BC site domain.
Is this possible at all? I assume the use of JSONP is needed, but does BC allow this or is there a workaround?

Views

363

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Mentor , Nov 25, 2014 Nov 25, 2014

Hmmm... I can't see 'Access-Control-Allow-Origin: *' inside BC's headers so

I don't think it will work. I'm sorry but I've never had to do it. I think

BC allows it only for some views, like the URLs used by apps, but not for

the standard frontend views. I might be wrong though.

On Wed, Nov 26, 2014 at 4:53 PM, Adam (Logo Pogo) <forums_noreply@adobe.com>

Votes

Translate

Translate
Mentor ,
Nov 25, 2014 Nov 25, 2014

Copy link to clipboard

Copied

You don't need JSONP to retrieve data from BC. JSONP is used when making

cross domain ajax calls. For example if you were to POST or PUT something

to BC using Ajax from another site.

On Wed, Nov 26, 2014 at 11:59 AM, Adam (Logo Pogo) <forums_noreply@adobe.com

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Nov 25, 2014 Nov 25, 2014

Copy link to clipboard

Copied

Thanks for your comment Mario.
Yes, I am wanting to retrieve data from BC from an external app using AJAX that is not on the same domain.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Mentor ,
Nov 25, 2014 Nov 25, 2014

Copy link to clipboard

Copied

Hmmm... I can't see 'Access-Control-Allow-Origin: *' inside BC's headers so

I don't think it will work. I'm sorry but I've never had to do it. I think

BC allows it only for some views, like the URLs used by apps, but not for

the standard frontend views. I might be wrong though.

On Wed, Nov 26, 2014 at 4:53 PM, Adam (Logo Pogo) <forums_noreply@adobe.com>

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guide ,
Dec 10, 2014 Dec 10, 2014

Copy link to clipboard

Copied

LATEST

Basically impossible until the new client aide API comes on, BC will only inject information server side into files with HTML extensions and you can't make (currently) a page template to output something that looks like a JS page without BC also injecting a <HTML><HEAD> information and killing your chance at dynamic javascript.

The only other way would be pulling the information via the SOAP API and using that on the remote site (injected into the page or whatever).

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines