Reputation: 4688
I have audio files saved in a folder on my server. They are called by JQuery JPlayer to be played. However if a person looks at the source of the page, they can find the location of the file and simply download it. I want to protect the files from being downloadable, but still allow JPlayer to play them. Is this possible?
I have tried denying the folder with .htaccess as well as password protecting the folder, but this prevents JPlayer from being able to play the files.
Upvotes: 4
Views: 6272
Reputation: 8396
It's impossible to stop a savvy user stealing your media. But if you like, you could
To save time, i suggest you accept whatever you publish can be copied / taken. So, why not publish
Recently, a widget allowing you to stream Paul McCartney's new album was published in the Guardian.. how this is "secure" i don't know, I opened Chrome Dev Tools Network tab and helped myself to anything "audio/mpeg"!
Upvotes: 2
Reputation: 23
You should be aware (just in case you're not) that if someone can play the file in their browser, there is nothing to stop them playing the file and using recording software to capture the audio.
Upvotes: 0
Reputation: 3719
I found a possible answer for you, using PHP: Solution using PHP sessions
It's a long thread, but there's code there that will help you.
Upvotes: 1