Integrating with dynamic data from Drupal

Hello,

I was wondering if there is any suggested/easy way to send dynamic data (i.e. images and text) to a hype document from a Drupal website. I am trying to create a simple portfolio listing and take advantage of some pretty animations I created in Hype while displaying content from my drupal 7 integration.

It's theoretical, as I haven't had a need to do this yet, but perhaps it would work like this...

  • A View would be used to generate JavaScript (You're still on Drupal 7, so this should work. I'm not sure if Drupal 8 allows JavaScript in a view. You might need to take extra steps to make that happen.)
  • The JavaScript basically saves your content as Global Variables, probably as an array (windows.data = [1,2,3])
  • The view doesn't display anything, besides JavaScript... except the Hype project, which can be added in the bottom part of the view.
  • Hype then uses its JavaScript to grab the data from the view and displays it accordingly.

This could work like this...

...where the elements in the Hype view display content based on data in an array.

2 Likes

This sounds like an interesting approach and it could work. I will try it and update this with any findings… Thank you.