Forum Discussion

dcronin135's avatar
dcronin135
Helpful | Level 5
6 years ago

Update a shared DropBox file without losing its DropBox shared link

I run a website for an organization, leveraging DropBox (Windows 10) for a monthly news video source. There is a media team that updates the one video file (news.mp4) monthly, that has a shared link reference with its code embedded into a html-video tag on a website.

I have only found one way to maintain an existing link, when updating this news.mp4 filename for the website. Leveraging some tricks from Linux and AIX, wanted to see if they would work on Windows. It seems to work in Windows too.

DropBox\Video <-- This is on a Windows 10 platform

C:\DropBox\Video> dir

01/25/2020 01:32 PM (467,676,373) news20200125.mp4
01/04/2020 08:43 PM (237,487,207) news20200104.mp4
01/04/2020 08:50 PM (237,487,207) news.mp4

This assumes you have already created a shared-DropBox link, and have it's code already working with an existing website.  The steps below will show you what I've found that seems to work for Windows, when updating the news.mp4 with news20201025.mp4 in this example.

1. First truncate news.mp4

C:\Dropbox\video> echo |set /p=>news.mp4

2. Append the new video to the existing shared news.mp4

C:> type news20200125.mp4 >> news.mp4

Test the auto streaming video code.   The existing shared DropBox link used on the website in the video-tag should still be valid.

How to auto stream them within the html-video tag for the 'src=' parameter.

Change the //www.dropbox portion of the link to //dl.dropbox


<div style="text-align: center;">
<video autoplay="" controls="" disablepictureinpicture="" height="300" onended="videoEnded(this)" poster="https://some.url.toJPG" width="500">
<source src="https://dl.dropbox.com/s/y14mx3e4ls79hru/news.mp4?dl=0" type="video/mp4" />
</video>
</div>
<script type="text/javascript">
function videoEnded(video) {
video.autoplay=false;
video.load();
};
</script>

About Dropbox tips & tricks

Node avatar for Dropbox tips & tricks
Learn how to get the most out of Dropbox with other users like you.402 PostsLatest Activity: 4 hours ago
345 Following

If you need more help you can view your support options (expected response time for an email or ticket is 24 hours), or contact us on X or Facebook.

For more info on available support options for your Dropbox plan, see this article.

If you found the answer to your question in this Community thread, please 'like' the post to say thanks and to let us know it was useful!