Support ⇒ Requests :: Archives ⇒ CPG_File::secure_download :: Archived ⇒ Community Forums ⇒ CPG Dragonfly™ CMS
Forum IndexRequests

Archived ⇒ CPG_File::secure_download


Can we get a flag in the secure_download function in the cpg_file class to set whether the download should be inline or an attachment? Right now, if you send an image through this function it will always prompt the user to download the file instead of displaying it in the browser (if possible). Or, if you have a better solution than duplicating the functionality of the secure_download function I would love to hear it.

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Win, Linux/1.3.34/4.0.26, 5.0.19/4.3.10, 5.1.2, 8.1.4(PostgresSQL)/9.0.6.1, CVS


Bumpity bump bump.

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Win, Linux/1.3.34/4.0.26, 5.0.19/4.3.10, 5.1.2, 8.1.4(PostgresSQL)/9.0.6.1, CVS


images always inline or optional?

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Fedora 25 / Apache 2.4.27 / MariaDB 10.1.26 / PHP 7.1.10 / Mercurial


I was thinking an optional parameter for the secure_download function that defaults to "attachment" - or whatever, maybe a constant. This way, you could use the function to send other files as inline, for example text files. What do you think?

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
Win, Linux/1.3.34/4.0.26, 5.0.19/4.3.10, 5.1.2, 8.1.4(PostgresSQL)/9.0.6.1, CVS


Second that. That would be very useful!

Server specs (Server OS / Apache / MySQL / PHP / DragonflyCMS):
FreeBSD 4.8-RELEASE/ 1.3.31/4.0.18/4.3.8/9.0.3.0

All times are UTC
This forum is locked: you cannot post, reply to, or edit topics. Forum IndexRequests
Page 1 of 1