Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial


Eric Castillo
Eric Castillo
6,427 Points

Storing and referencing Audio and Video files?

Nick mentions that if we want to store audio and video files, instead of doing it locally, we should use a file hosting site like google drive or dropbox. In the examples, we are referencing the files using a provided site URL.

But let's say we're just starting to create a page on our desktop computers and we have a bunch of files on our dropbox that we are referencing in the HTML code:

When it comes time to upload the site, as well as the audio/video files, to our server that hosts our domain, do we need to change each and every source to point to the new address? Is there any way to automate this or avoid having to change the address all together?

1 Answer

Jason Anders
Jason Anders
Treehouse Moderator 145,858 Points

Hi Eric,

I'm not sure I'm completely understanding your question, as you didn't link to the video in question.
Without the context of the video and Nick's comment, I'm only guessing... Sorry.

If you're already hosting the files on dropbox, the URL used to access them is not going to change once you upload the site to your server. so nothing in the HTML file will need to change. Local hosting or remote hosting will still use the same URL to access the file, as you are not moving the files, just your site.

If you're talking about actually storing those files with your site files on the server, then you really shouldn't be using dropbox as you develop locally, as all relevant files should be part of the same file tree and then all uploaded all at once.

If these are not what you are wondering, please repost a new thread, but link directly from the video where Nick makes this comment. To do this, you simply click the Get Help button located at the bottom right of the video page.

Hope this does help. :) :dizzy:

Eric Castillo
Eric Castillo
6,427 Points

Hi Jason, Thanks for your answer and apologies if I was unclear but your answer was helpful. Basically, I was just picturing a situation in which a site needed to change the media hosting site. I assume that the person coding the site needs to change the href and src tags in the code.

Sounds tedious but I can't think of another way! Thanks