Viewing PDF Image Blob
Posted: Wed Aug 19, 2009 6:38 am
Hi there.
I've got a pdf stored in the database (name, type, content, size)
I've made a 'view pdf' link which needs to show the blob pdf in the browser...
This passes the pdf name to the following script...
And I get the following error...
Warning: Cannot modify header information - headers already sent
Is $name the right one to use?
Any help will be much apreciated. Other tutorials on line seem to reall over complicate things.
I've got a pdf stored in the database (name, type, content, size)
I've made a 'view pdf' link which needs to show the blob pdf in the browser...
Code: Select all
<a href='showpdf.php?name=".$r['name']."' class='links'>Download Course PDF</a>Code: Select all
<?php
include("connect_course.php");
$name=$_GET['name'];
header("Content-Type: application/pdf");
echo $name;
exit();
?>And I get the following error...
Warning: Cannot modify header information - headers already sent
Is $name the right one to use?
Any help will be much apreciated. Other tutorials on line seem to reall over complicate things.