Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter outofhouse

    (@outofhouse)

    If so, where would I place the code?

    Something like:

    <?php
    echo $myString;
    echo"<p>Notes to the editor<p/>;
    ?>
    Plugin Author Neerav D.

    (@n33rav)

    Instruction for version 2.3.1

    In file wp-post-to-pdf/wp-post-to-pdf.php

    Append your code to $html variable after line 342

    $html .= $myString;
    $html .= “<p>Notes to the editor<p/>”;

    Thread Starter outofhouse

    (@outofhouse)

    Hi Neerav

    Doesn’t seem to be working for me!
    Here’s where I put the code:

    $html .= htmlspecialchars_decode(htmlentities($post->post_content, ENT_NOQUOTES, 'UTF-8', false), ENT_NOQUOTES);
                $dom = new simple_html_dom();
                $dom->load($html);
    
                foreach($dom->find('img') as $e){
                    $e->align = null;
                    $e->outertext = '<div style="text-align:center;">' . $e->outertext . '</div>';
                }
    
                $html = $dom->save();
    
                $dom->clear();
                $html .= $myString;
    $html .= "<p>Notes to the editor<p/>";
    
                // Print text using writeHTML
                $pdf->writeHTML($html, true, 0, true, 0);
    
                // ---------------------------------------------------------
                // Close and output PDF document
                // This method has several options, check the source code documentation for more information.

    website: http://www.ooh-websites.co.uk/ovalmedical/oval-medical-collaborates-with-the-cambridge-university-mba-venture-project-2/

    Any ideas or have I simply put it in the wrong place?!

    Plugin Author Neerav D.

    (@n33rav)

    You have put the code at right place.

    I suspect you forget to delete cached PDF files. You can delete them from WP Post to PDF settings page.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘[Plugin: WP Post to PDF] Displaying a simple text footer’ is closed to new replies.