From a pylon controller action, instead of rendering a template, I want to send a file to the user to download. In languages like PHP, I can do the this thing like following. How can I do this in pylons?
header("Content-Type: application/octet-stream");
header("Content-Transfer-Encoding: Binary");
header("Content-disposition: attachment; filename=\"file.exe\"");
echo readfile($url);