Jump to content

Recommended Posts

Posted

Hello,

I need to connect two PW sites, both with rather big pagetrees. When adding a page to site A, the editor should be able to select one or more related pages from site B (one is an editorial news site, the other a product cataloque)

My idea was to build an API for site B which writes JSON data of the applicable pages and feed that into my custom inputfield which would be heavily influenced by PageListSelect. Now my questions:

Has anyone built something similar? Since this would be my first custom field / inputfield, where should I look for help? Does this sound like a reasonable approach or are there other ways to connect two PW sites?

Thanks for any help,

thomas

Posted

Servus mr-fan,

thanks for the hints. I now built the inputfield pretty much like described above. I duplicated PageListSelectMultiple for site A and changed the code so it loads JSONP data from site B. On site B I have a simple API that returns data suitable for ProcessPageList. Needs more testing but seems to work so far.

Thanks,

thomas

  • Like 2
Posted

hi thomas,

how do you manage access control on site B? in other words, how does site B know what it is allowed to return to the user of site A? or is it all public data?

thanks

Posted

Hi Bernhard,

since it's a product cataloque and all that's needed in site A is the products I simply restrict site B's API to the products folder and it's children.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...