Post the php here, I'm sure NF or similar here will spot the problem in no time.
$pdf->Output("Invoice.pdf", "I");
switch($dest)
{
case 'I':
//Send to standard output
if(isset($HTTP_SERVER_VARS['SERVER_NAME']))
//if (true)
{
//We send to a browser
[B]Header('Content-Type: application/pdf');[/B]
if(headers_sent())
$this->Error('Some data has already been output to browser, can\'t send PDF file');
Header('Content-Length: '.strlen($this->buffer));
Header('Content-disposition: inline; filename='.$name);
}
echo $this->buffer;
break;
if(isset($HTTP_SERVER_VARS['SERVER_NAME']))
$HTTP_SERVER_VARS [deprecated]
$_SERVER -- $HTTP_SERVER_VARS [deprecated] — Server and execution environment information
Report a bug
Description
$_SERVER is an array containing information such as headers, paths, and script locations. The entries in this array are created by the web server. There is no guarantee that every web server will provide any of these; servers may omit some, or provide others not listed here. That said, a large number of these variables are accounted for in the » CGI/1.1 specification, so you should be able to expect those.
$HTTP_SERVER_VARS contains the same initial information, but is not a superglobal. (Note that $HTTP_SERVER_VARS and $_SERVER are different variables and that PHP handles them as such)

case 'I':
//Send to standard output
//if(isset($HTTP_SERVER_VARS['SERVER_NAME']))
[B]if(isset($_SERVER['SERVER_NAME']))[/B]
//if (true)
{
//We send to a browser
Header('Content-Type: application/pdf');
if(headers_sent())
$this->Error('Some data has already been output to browser, can\'t send PDF file');
Header('Content-Length: '.strlen($this->buffer));
Header('Content-disposition: inline; filename='.$name);
}
echo $this->buffer;
break;

error_reporting(E_ALL);

I restarted apache out of desperation.
It works.
A luverly little pdf gets opened up.
Off for a glass of vino, before coming back and pozzie repping everyone in this thread. Time for some suity loving, you better buckle up.![]()

I restarted apache out of desperation.
It works.
A luverly little pdf gets opened up.
Off for a glass of vino, before coming back and pozzie repping everyone in this thread. Time for some suity loving, you better buckle up.![]()

So it looks like as I built this machine from the latest bits the php version is too high and hence I have a build problem.
I restarted apache out of desperation.
It works.
A luverly little pdf gets opened up.![]()
