I have a wordpress site in my droplet and i have a directory folder named
"tv_channels" where i put many html and php files which is not ally with
wordpress...... whenever i post anything then i embed a file from that directory
but users are going only that folder directly and access my those php/html files.
now i want to block that url for user besides i want to embed my files in post.....
Can you guys help me out??
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
It would be better if we had more details, but assuming you are running apache, and assuming you mean that users are able to view what’s in your “tv_channels” folder directly, then this answer should help.
If you are on NginX, you could block access to that folder, and then have a backend processor, like PHP, grab and display the file directly to the user. That way only humans should be able to access the file, and only one at a time, as displayed by the page.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.