MaxCDN Integration with 5.7

Permalink
Hello,

I recently integrated a website of mine with MaxCDN in hopes to increase speeds on certain pages that are serving up a lot of PDFs.

Simply using the <base> tag and adjusting some of my references I was able to get all of the CSS and JS routed through the CDN but I am having an issue getting the PDFs and Images from the File Manager to work.

What I need to do is modify the output of a file link when uploaded from "www.example.com/files/file_name.pdf" to "cdn.example.com/files/file_name.pdf". Does anyone have any idea where I go to change this?

Any help is much appreciated!

tarilotta
 
mrjcgoodwin replied on at Permalink Reply
mrjcgoodwin
There's been a few threads in the past about CDN integration with C5.

This one the other day:https://www.concrete5.org/community/forums/customizing_c5/cdn-integr...

Bottom line is that it doesn't seem to be straight forward!
tarilotta replied on at Permalink Reply
tarilotta
There were so many add-ons and work arounds in 5.6 and below it is hard to imagine that, given how heavily web developers rely on a good CDN, there wouldn't be a relatively easy way to integrate it.

I am thinking there should be a way to manipulate the File Storage Locations option by adding a custom type that will point to a subdomain but I am not sure how to go about this...
Gondwana replied on at Permalink Reply
Gondwana
I don't know what I'm talking about, but is this relevant?http://documentation.concrete5.org/developers/working-with-files-an...
tarilotta replied on at Permalink Reply
tarilotta
That is the documentation I was talking about in my previous response but I am unsure of how you make it point to a sub-domain. I just purchased the Amazon S3 add-on and plan to dig through that to see if I can figure out how they did it.
tarilotta replied on at Permalink Reply
tarilotta
Alright, so I feel like an idiot... I don't know how I didn't realize this the first time I looked at it but pointing to a sub-domain is quite simple.

Create a new location in the file manager settings and make the absolute path "/home/dir/public_html/sub-domain/path" and the relative url can just be "/sub-domain/path"

This didn't help me with my specific issue but as far as not being able to save files to a sub-domain, that definitely works.