Note that there are some explanatory texts on larger screens.

plurals
  1. POconvert html file to pdf using dompdf
    text
    copied!<p>How do I properly use dompdf to convert html files into pdf. I'm doing something like this:</p> <pre><code>&lt;?php require_once("lib/dompdf/dompdf_config.inc.php"); $file = "checkout.html"; $dompdf = new DOMPDF(); $dompdf-&gt;load_html_file($file); $dompdf-&gt;render(); $dompdf-&gt;stream("sample.pdf"); ?&gt; </code></pre> <p>But I get this error:</p> <pre><code>Fatal error: Call to undefined method Inline_Frame_Decorator::normalise() in C:\wamp\www\pos\php\lib\dompdf\include\table_frame_decorator.cls.php on line 252 </code></pre> <p>How do I solve this, please enlighten me. Thanks.</p> <p><strong>Update</strong> Here are the contents of checkout.html</p> <pre><code>&lt;table border="0"&gt; &lt;th colspan="10"&gt;Product&lt;/th&gt; &lt;th&gt;Quantity&lt;/th&gt; &lt;th&gt;Price&lt;/th&gt; &lt;!--&lt;th&gt;Discount&lt;/th&gt;&lt;!-- commented out jan 21--&gt; &lt;th&gt;Subtotal&lt;/th&gt; &lt;!-- fetch values from reports and prod_table using the qtysoldfetcher query--&gt; &lt;tr&gt; &lt;td colspan="10"&gt;Boysen&lt;/td&gt; &lt;td&gt;4&lt;/td&gt; &lt;td&gt;900&lt;/td&gt; &lt;!-- &lt;td&gt;&lt;/td&gt; --&gt;&lt;!-- commented out jan 21--&gt; &lt;td&gt;3600&lt;/td&gt; &lt;/tr&gt; &lt;h3 id="wyt"&gt;Sales Transaction Summary&lt;/h3&gt;&lt;a href="pdfqtysold.php"&gt;&lt;img id="tablez" src="../img/system/icons/Oficina-PDF-icon.png"&gt;&lt;/img&gt;&lt;/a&gt; &lt;tr&gt; &lt;td&gt;Total Bill: &lt;/td&gt; &lt;td colspan="8"&gt;3600&lt;/td&gt; &lt;!--added jan 19 --&gt; &lt;/tr&gt; &lt;tr&gt; &lt;td&gt;Amount paid: &lt;/td&gt; &lt;td colspan="8"&gt;900&lt;/td&gt; &lt;/tr&gt; &lt;tr&gt; &lt;td&gt;Change: &lt;/td&gt; &lt;td colspan="8"&gt;&lt;/td&gt; &lt;/tr&gt; &lt;tr&gt; &lt;td&gt;Credit: &lt;/td&gt; &lt;td colspan="8"&gt;2700&lt;/td&gt; &lt;/tr&gt; &lt;tr&gt; &lt;td&gt;Date: &lt;/td&gt; &lt;td colspan="8"&gt;2011-01-28 11:13:52&lt;/td&gt; &lt;/tr&gt; &lt;tr&gt; &lt;td&gt;Bought by: &lt;/td&gt; &lt;td colspan="8"&gt;Asakura, Yoh&lt;/td&gt; &lt;/tr&gt; &lt;!--end--&gt; &lt;/table&gt; </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload