Hype on Nationbuilder: Cloudfront File Structure

resources

#1

Hi, I am thinking of using Hype for a presentation on a Nationbuilder site. My issue is that Nationbuilder works much differently when it comes to resources than most sites/servers. While your domain may be www.sitename.com/page_name the resources for that site would be at:

https://d3n8a8pro7vhmx.cloudfront.net/sitename/pages/41/features/original/imagefile.jpg?1428541139

Since Hype calls on resources via javascript, would this difference cause any issues so long as I modified the url’s of the resources in the javascript files? I ask due to restrictions on cross-domain calls in javascript. Nationbuilder doesn’t allow nested files, so before I upload a TON of files to a single directory, I want to get this right and have minimal knowledge of javascript.


#2

If you upload all assets in a Hype Resources folder, you can reference the JS file by using its full URL. As long as all files are in the same folder, it should work as expected.

It looks like all uploads (for page 41, for example) would go into: sitename/pages/41/features/original/

When loading a Hype JS file, content like images and the Hype.js runtime, all content is loaded from the same folder.


#3

So the Nationbuilder system did in fact change the URL’s in the JS files for me automatically. However, the system does not accept the @ symbol, replacing it with an underscore. I had to correct for those URLs but otherwise it works great. Thanks for the help and I hope this thread proves useful to someone else.