|
-
Aug 27th, 2010, 07:15 AM
#1
Thread Starter
Hyperactive Member
Caching video's
I promised a mate I'll ask around about a little issue he's having.
Having a website, where user's log in and based on their roles can watch training videos.
Each video pretty large and take a while to buffer. After you watched it, it's ok to watch it again, as it's cached on the local machine.
However when you restart the machines of course those caches are cleared and going to your video's again, you start all over.
Want to figure out something that will work if different users, using different accounts use the same machine, so "save to your computer" is not really a solution.
Any ideas?
-
Aug 27th, 2010, 11:57 AM
#2
Re: Caching video's
you could try making a script that streamed the file to the user and also sent a header that said to cache the file for longer. if your computers clear the cache every restart, though, this may not matter.
from PHP.net:
PHP Code:
<?php // seconds, minutes, hours, days $expires = 60 * 60 * 24 * 14; // 14 days header("Pragma: public"); header("Cache-Control: maxage=" . $expires); header('Expires: ' . gmdate('D, d M Y H:i:s', time() + $expires) . ' GMT'); ?>
-
Aug 30th, 2010, 11:01 PM
#3
Re: Caching video's
Compress the videos more.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|