• Resolved DownunderDabbler

    (@downunderdabbler)


    Version of this plugin.
    1.0.5

    Theme in use, and version.
    Responsive Pro v: 1.0.1 with Responsive Pro child theme v: 1.0.0 (minimal custom css)

    List of inactive plugins installed (and versions).
    Document Gallery 2.1
    Fast Secure Contact Form 4.0.21
    FooBox Free Image Lightbox 1.0.3
    Google Doc Embedder 2.5.14
    Media Library Categories 1.4.10
    Members 0.2.4

    List of active plugins.
    Akismet 3.0.1
    All-in-One Event Calendar by Time.ly 2.0.13
    BuddyPress 2.0.1
    Responsive Add Ons 1.0.6
    Table of Contents Plus 1407
    TablePress 1.4
    UpdraftPlus – Backup/Restore 1.9.17.18
    Vanilla PDF Embed 0.0.7
    Wordfence Security 5.1.5
    WP-Optimize 1.8.6
    WP Post to PDF Enhanced 1.0.5

    Brief description of the problem, as in: type of content, expected output, resulting output.
    Have just installed your plugin and tried it on 2 pages, 1 with 4.7K words and one with 23K words. Both pages have a generated TOC and include the same small png graphic.

    The smaller page downloads fine and the resultant pdf has a very pleasing clickable TOC. The second page eventually aborts with the message: Fatal error: Maximum execution time of 30 seconds exceeded in /home/hhcmember/hhci.org.au/batin101/wp-content/plugins/wp-post-to-pdf-enhanced/tcpdf/tcpdf.php on line 19129

    With all plugins deactivated except yours, the same error occurs but on line 1795

    Thank you for a great plugin. 23K is a large policy document ??

    Hakim

    https://www.ads-software.com/plugins/wp-post-to-pdf-enhanced/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Thread Starter DownunderDabbler

    (@downunderdabbler)

    Forgot to mention: the only difference between the two documents apart from size is that the larger one uses a table generated by Tablepress 1.4

    Thank you very much for your work for the community.

    Hakim

    Plugin Author Lewis Rosenthal

    (@lewisr)

    Hi, Hakim…

    Thanks for your kind words; glad that you are pleased with the output.

    The answer lies in the error message itself:

    Fatal error: Maximum execution time of 30 seconds exceeded

    It is taking longer than 30 seconds to generate the document, which isn’t out of the question for a large file with lots of words.

    If you self-host, you can increase the max_execution_time parameter in php.ini on the server to, say, 45 or 60 seconds (for most modern PHP installations, 60 seconds is a normal limit; 30 seems a bit short).

    If you do not have access to the server configuration, you should be able to override this setting in your wp-config.php file by adding something like:

    set_time_limit(60);

    above the “/* That’s all, stop editing! Happy blogging. */” comment.

    Or, you could insert the following snippet in .htaccess in the root of your site:

    <IfModule mod_php5.c>
      php_value max_execution_time 60
    </IfModule>

    We likely just need to get a little more time to build the pdf, that’s all.

    Cheers

    Lewis

    PS – We’ll see how the table is generated in the resulting pdf. That may be a separate issue, as we don’t do tables very well, yet. ??

    Thread Starter DownunderDabbler

    (@downunderdabbler)

    Many thanks Lewis,

    Yes, the table is not ‘pretty’ but the content is roughly where it should be. I might restructure that section so that there is clear vertical separation between what was in different cells of the table. The horizontal separation is fine.

    I changed the setting in the wp-config.php as you suggested (it seemed the easiest option)and that worked fine.

    I also added some text to appear below the PDF icon:
    “Click the PDF icon to download the file.
    Be patient! It is a large file and can take almost
    a minute before the save file dialog box opens.”

    Ideally I would have a message that popped up when the PDF icon was clicked but that is beyond my current skills – I am still learning what the various css selectors are … ??

    Again, thank you for a very useful plugin and the support to go with it.

    Hakim

    Thread Starter DownunderDabbler

    (@downunderdabbler)

    Again, a PS

    The links in the table of contents (TOC) are based on H3 and H4 formatting. With the shorter document the H3 links work as expected but the H4 links don’t work. In the longer document none of the links work.

    If I replaced the the TOC plugin with id and href links would that make a difference? I guess I shall try it and see what happens.

    Hakim

    Thread Starter DownunderDabbler

    (@downunderdabbler)

    The original problem is fixed so I will mark it resolved, with much gratitude for the prompt and effective support.

    Hakim

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Time out error on long page’ is closed to new replies.