This is an archived forum post. The information may be outdated. Contact us if you have any questions.

Problem at Mathematical Symbols display

sgkavalase wrote on 2014-01-08:
Hello,
I am using API. When I generate pdf with mathematical symbols such as theta,pi in symbolic forms it is not display correctely. All PDF is generate OK but mathematical symbols are not displayed properly.
support wrote on 2014-01-08:
Hello,

If you can post here a sample HTML code which demostrates the problem, we will look into it.
sgkavalase wrote on 2014-01-09:
It is an PHP script file. I want to display mathematical formalas dynamically which is stored in database. I have code only to rerieve from database display on the browser using session variable. It is showing correctly on browser. Only problems at PDF generation & code to generate PDF is:

<?php
require_once('/pdfcrowd/pdfcrowd.php');
$prn=$_SESSION['exam'];
try
{
$client = new Pdfcrowd("xxx", "xxx");

$pdf = $client->convertHtml($prn);


// set HTTP response headers

header("Content-Type: application/pdf");
header("Accept-Charset: utf-8");
//header('Content-Type: text/html; charset=utf-8');
header("Cache-Control: no-cache");
header("Accept-Ranges: none");
header("Content-Disposition: attachment; filename=\"Exam_Paper.pdf\"");

// send the generated PDF
echo $pdf;
}
catch(PdfcrowdException $why)
{
echo "Pdfcrowd Error: " . $why;
}

exit;
?>
support wrote on 2014-01-09:
Hello,

Your code looks fine, but unfortunately this not enough information for me to troubleshoot the issue. I need to know the contents of the $prn variable. Could you post a sample of the contents of $prn?