pues no aqui es donde me marca el error por favor AYUDAAAA¡¡¡¡
Código PHP:
switch($dest)
{
case 'I':
//Send to standard output
if(isset($HTTP_SERVER_VARS['SERVER_NAME']))
{
//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;
case 'D':
//Download file
if(isset($HTTP_SERVER_VARS['HTTP_USER_AGENT']) and strpos($HTTP_SERVER_VARS['HTTP_USER_AGENT'],'MSIE'))
Header('Content-Type: application/force-download');
else
Header('Content-Type: application/octet-stream');
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: attachment; filename='.$name);
echo $this->buffer;
break;
case 'F':
//Save to local file
aqui marca el ------->>$f=fopen($name,'wb');
error if(!$f)
$this->Error('Unable to create output file: '.$name);
fwrite($f,$this->buffer,strlen($this->buffer));
fclose($f);
break;
case 'S':
//Return as a string
return $this->buffer;
default:
$this->Error('Incorrect output destination: '.$dest);
}
return '';
}