Do a resource download network, download resources can not access, technical solutions

Source: Internet
Author: User
The most recent resource download network, upload files to the development folder, no encrypted files, but the download can be directly accessed directly through the address, thus adding the. htaccess file prevents direct access to the download, but it cannot be downloaded when the program is read. I just copy the original download directory files from the program, but this is inefficient, so that the duplication of replication and so on, there is a good solution, whether the cache can be used to cache the downloaded files? If the line, how the code is written. My brother is not technically enough


Reply to discussion (solution)

Seemingly as long as in the resource directory to fly. htaccess
One word
Deny from all

Seemingly as long as in the resource directory to fly. htaccess
One word
Deny from all



This I also use, but can not download, I now the purpose is only through the program download, if this is used. htaccess file programs are not available for download

The uploaded file is placed on the top level of the site directory and is read and written by the program.


Seemingly as long as in the resource directory to fly. htaccess
One word
Deny from all



This I also use, but can not download, I now the purpose is only through the program download, if this is used. htaccess file programs are not available for download


No, how can I do that?



Seemingly as long as in the resource directory to fly. htaccess
One word
Deny from all



This I also use, but can not download, I now the purpose is only through the program download, if this is used. htaccess file programs are not available for download


No, how can I do that?


The downloaded code has a header or something. Use that on the line, seemingly, not very sure, with the actual results prevail

Http://www.cnblogs.com/c840136/articles/PHP_header_download.html
File operations Read server-local files, IP-independent, seemingly, not very sure

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.