<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[FrontAccounting forum — Custom PDF Header]]></title>
		<link>https://frontaccounting.com/punbb/viewtopic.php?id=10709</link>
		<atom:link href="https://frontaccounting.com/punbb/extern.php?action=feed&amp;tid=10709&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in Custom PDF Header.]]></description>
		<lastBuildDate>Sun, 08 Feb 2026 10:14:30 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Custom PDF Header]]></title>
			<link>https://frontaccounting.com/punbb/viewtopic.php?pid=43829#p43829</link>
			<description><![CDATA[<p>I can see there is a function in pdf_report.inc that includes some Customer Header Template from<br />/reporting/forms folder</p><div class="codebox"><pre><code>function NewPage() 
    {
        if ($this-&gt;pageNumber==0)
        {
            // check if there is pdf header template for this report
            // and set if it is found
            $tmpl_pdf = find_custom_file(&quot;/reporting/forms/&quot;.$this-&gt;headerTmpl.&quot;.pdf&quot;);
            if ($tmpl_pdf) {
                $this-&gt;tmplSize = $this-&gt;setSourceFile($tmpl_pdf);
            }
        }

        $this-&gt;pageNumber++;
        parent::newPage();

        if ($this-&gt;tmplSize) {
            $this-&gt;row = $this-&gt;pageHeight - $this-&gt;topMargin; // reset row
            $id = $this-&gt;importPage(min($this-&gt;pageNumber, $this-&gt;tmplSize));
            $this-&gt;useTemplate($id);
        }

        // include related php file if any
        $tmpl_php = find_custom_file(&quot;/reporting/forms/&quot;.$this-&gt;headerTmpl.&quot;.php&quot;);
        if ($tmpl_php) {
            include($tmpl_php);
        }

        if (method_exists($this, $this-&gt;headerTmpl))    // draw predefined page layout if any
            $this-&gt;{$this-&gt;headerTmpl}();
    }</code></pre></div><p>I am not sure How to use this If I add some custom header page in my module. Any help, ideas, sample?</p>]]></description>
			<author><![CDATA[null@example.com (boxygen)]]></author>
			<pubDate>Sun, 08 Feb 2026 10:14:30 +0000</pubDate>
			<guid>https://frontaccounting.com/punbb/viewtopic.php?pid=43829#p43829</guid>
		</item>
	</channel>
</rss>
