Some functions on this portal require JavaScript but your browser does not support it or it has been disabled.
Skip to main content
Tuesday 01 March 2011 6:35:42 am - 2 replies
Peter Keung
Tuesday 01 March 2011 8:15:19 am
The proper way to stop further eZ Publish execution is to use eZExecution::cleanExit(); instead of die(); or exit(); Perhaps that is what you are missing.
http://www.mugo.ca Mugo Web, eZ Partner in Vancouver, Canada
Fou Jino
Wednesday 02 March 2011 1:08:59 am
Nop Peter, but I found a solution ;
ob_start();
$path = "[...]";
$file = "[...]"
$filesize = filesize($path.$file);
if(file_exists($path.$file)) {
header('Content-type: application/force-download');
header('Content-disposition: attachment; filename="'. $file .'"');
header('Content-length: '. $filesize ); readfile( $path.$file );
}
ob_end_flush();
I used ob_start() & ob_flush to active output buffering, and it works perfectly :)
Foujino ~ http://www.foujino-blog.be
You must be logged in to post messages in this topic!