PREVENT VIDEO SRC FROM DOWNLOADING

hi
so everyone who know inspect element can simply find my video src url and then download it
i want prevent that so i heard about blob urls are they working only in javascript? or there is a way i can make it in php
or maybe there is another way in php to protect url?

if i have to use blob i need add code when i upload video and then it makes own link or i can use ready link like myweb.com/videos/video1.mp4 to convert it to blob?

Are you just trying to prevent direct access?

well ye i dont want they see it myweb.com/videos/video.mp4 if they will go to that link they can easily download video

I would move the files behind public access, and have a script that pulls them based on an id or something. You can then add a line in the script that doesn’t allow direct access without a token or other authenticator.

Topic of interest

also i wanted ask i dont have .htacces in my website i clicked show hidden files searched for it nothing i searched for info in my host page
it told me

If you do not see .htaccess file, there might be 2 possible issues: 1. You may have configured your cPanel File Manager or FTP client not to show hidden (dot) files. Please configure your FTP client or File Manager to display these files. 2. This file is not created or uploaded to your public_html directory yet. Please create and upload it first.

it is easy to create it? i already searched for it can i download some other htaccess file or i need change some details

What do you want the htaccess file to do? It isn’t there just to be there, it has rules to implement and serves a purpose.

i found info that i need add something in htaccess file so others wont be able to go to links like
myweb.com/videos/ - they will see all videos i know it will still allow you go to myweb.com/videos/video1.mp4 but still i want
access to myweb.com/videos/ is blocked

Just add a blank index.html file and it prevents people from seeing the contents of the directory.

There are many resources available to block access to the directory itself.

[code]# disable directory browsing
Options All -Indexes

prevent folder listing

IndexIgnore *

prevent access to any file

<FilesMatch “^.*$”>
Order Allow,Deny
Deny from all
[/code]

if i have index.php already created i still can create index.html page and it will work?

It would be one or the other. If you have an index.php page in that directory, you can’t see the contents of that directory however.

ah ye THANKS YOU VERY MUCH helped me a lot

Sponsor our Newsletter | Privacy Policy | Terms of Service