shenuke Posted January 31, 2009 Share Posted January 31, 2009 Hello, I used tcpdf to solved generate PDF. It worked for my language.But I don't know why only on price summation not display currency symbol for my language ?*Display price summation* $pdf->Ln(5); $pdf->SetFont(self::fontname(), 'B', 8); $width = 165; $pdf->Cell($width, 0, self::l('Total products TI').' : ', 0, 0, 'R'); $totalProductsTi = self::$order->getTotalProductsWithTaxes((self::$orderSlip ? self::$order->products : false)); $pdf->Cell(0, 0, self::convertSign(Tools::displayPrice($totalProductsTi, self::$currency, true, false)), 0, 0, 'R'); $pdf->Ln(4); if (self::$order->total_discounts != '0.00') { $pdf->Cell($width, 0, self::l('Total discounts').' : ', 0, 0, 'R'); $pdf->Cell(0, 0, (!self::$orderSlip ? '-' : '').self::convertSign(Tools::displayPrice(self::$order->total_discounts, self::$currency, true, false)), 0, 0, 'R'); $pdf->Ln(4); } if(isset(self::$order->total_wrapping) and (floatval(self::$order->total_wrapping) > 0)) { $pdf->Cell($width, 0, self::l('Total wrapping').' : ', 0, 0, 'R'); $pdf->Cell(0, 0, self::convertSign(Tools::displayPrice(self::$order->total_wrapping, self::$currency, true, false)), 0, 0, 'R'); $pdf->Ln(4); } if (self::$order->total_shipping != '0.00' AND !self::$orderSlip) { $pdf->Cell($width, 0, self::l('Total shipping').' : ', 0, 0, 'R'); $pdf->Cell(0, 0, self::convertSign(Tools::displayPrice(self::$order->total_shipping, self::$currency, true, false)), 0, 0, 'R'); $pdf->Ln(4); } if (!self::$orderSlip) { $pdf->Cell($width, 0, self::l('Total with Tax').' : ', 0, 0, 'R'); $pdf->Cell(0, 0, self::convertSign(Tools::displayPrice((self::$orderSlip ? ($totalProductsTi + self::$order->total_discounts + (self::$orderSlip ? 0 : self::$order->total_shipping)) : self::$order->total_paid), self::$currency, true, false)), 0, 0, 'R'); $pdf->Ln(4); } if ($ecotax != '0.00' AND !self::$orderSlip) { $pdf->Cell($width, 0, self::l('Eco-participation').' : ', 0, 0, 'R'); $pdf->Cell(0, 0, self::convertSign(Tools::displayPrice($ecotax, self::$currency, true, false)), 0, 0, 'R'); $pdf->Ln(5); } $pdf->TaxTab(); Hook::PDFInvoice($pdf, self::$order->id); if (!$multiple) return $pdf->Output(sprintf('d', self::$order->id).'.pdf', $mode); } Please...Thanks, Link to comment Share on other sites More sharing options...
Damien Metzger Posted January 31, 2009 Share Posted January 31, 2009 What's your current currency ?Problems like that are not unheard of, we need to replace the € (EUR) symbol with char(128). Link to comment Share on other sites More sharing options...
shenuke Posted January 31, 2009 Author Share Posted January 31, 2009 Thai language. ฿ (THB), cp874, freeserifPlease see attachment. Link to comment Share on other sites More sharing options...
Recommended Posts