Support

Admin Tools

#33206 PDF Direct Download

Posted in ‘Admin Tools for Joomla! 4 & 5’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

Joomla! version
n/a
PHP version
n/a
Admin Tools version
n/a

Latest post by on Wednesday, 15 July 2020 17:17 CDT

msreyes

I am using another tool to upload PDF's.  That works no problem, and it does rename them too to something random.

This directory is located in my public_html folder.... so it is outside images and media. (public_html/fileshere for example)

In this specific directory, how do I stop direct download of the PDF?  I am trying to limit the download of these files from within the front end joomla login of a user.

I'm sorry if this has been asked 1000 times, I just can't figure it out.

dlb

I think you can accomplish that by copying the .htaccess file from the /administrator/components/com_akeeba/backup folder to your /fileshere folder.

That .htaccess file limits access to the folder to localhost.  That way, you can download the files through the web server but not directly via URL.  We want to do the same thing with the default output folder.



Dale L. Brackin
Support Specialist


us.gifEnglish: native


Please keep in mind my timezone and cultural differences when reading my replies. Thank you!


????
My time zone is EST (UTC -5) (click here to see my current time in Philadelphia, PA)

msreyes

This did not work.  And I don't use Akeba backup, this was Admin Tools so the directory listing did not match.

I agree the .htaccess needs to be modified, and I use to do it manually before Admin Tools.  Just can't figure out how to allow/not allow PDFs in specific directories.

dlb

I apologize, I should have noticed that you didn't have Akeeba Backup.  Here's the contents of that file:

<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
</IfModule>
<IfModule mod_authz_core.c>
  <RequireAll>
    Require all denied
  </RequireAll>
</IfModule>

You don't put the code in your main .htaccess file, make a new .htaccess in the folder you want to restrict.



Dale L. Brackin
Support Specialist


us.gifEnglish: native


Please keep in mind my timezone and cultural differences when reading my replies. Thank you!


????
My time zone is EST (UTC -5) (click here to see my current time in Philadelphia, PA)

System Task
system
This ticket has been automatically closed. All tickets which have been inactive for a long time are automatically closed. If you believe that this ticket was closed in error, please contact us.

Support Information

Working hours: We are open Monday to Friday, 9am to 7pm Cyprus timezone (EET / EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets outside of our working hours, but we cannot respond to them until we're back at the office.

Support policy: We would like to kindly inform you that when using our support you have already agreed to the Support Policy which is part of our Terms of Service. Thank you for your understanding and for helping us help you!