I'm looking for a method to embed the document in the browser (in IE). I have a
But it'll open the document in another window. I want to show it like this.Code:<?php require_once(dirname(__FILE__) . '/../../lib/lekoi/helper/WebHelper.php'); $relativePathFilename = 'PFC-1000-6-5546.vsd'; $filename = '/tmxpage/apache/htdocs/changecontrol/' . $relativePathFilename; $path = pathinfo($filename); header('Content-Type: ' . get_content_type($path['extension'])); header('Content-Transfer-Encoding: binary'); header('Content-Length: ' . filesize($filename)); header('Content-Disposition: attachment; filename="' . basename($filename) . '"'); @readfile($filename); ?>


Reply With Quote
