Skip to Main Content

How to create a download service

Volker HeiselmayerMay 30 2017 — edited Jun 7 2017

Hi!

I'd like to create an own download service where I provide special files for download.

Example:

URL: <my_host>/cs/idcplg?IdcService=DOWNLOAD_FILE&id=8

Internally I have the file "myfile.zip" (automatically created)

How can I send the file to the browser? How can I set custom headers?

Like PHP:

header('Content-Type: application/octet-stream');

echo file_get_content('data/my_file.zip');

Thanks!

BR,

    Volker

This post has been answered by Volker Heiselmayer on Jun 2 2017
Jump to Answer
Comments
Post Details
Added on May 30 2017
18 comments
411 views