WordPress.org

Ready to get started?Download WordPress

Forums

WP Post to PDF
[resolved] How do I make this plugin respect URL parameters? (7 posts)

  1. bbergman
    Member
    Posted 2 years ago #

    I've contacted the developer directly, but have not heard anything back, so I'm trying this support forum.

    Basically, this plugin works awesomely, but it doesn't respect additional URL parameters when it executes. For example, if I have a static page:

    http://www.example.com/my-page

    Then the PDF link generated is 'www.example.com/my-page?format=pdf', which is great and works fine. However, if the URL has a passed parameter, like:

    http://www.example.com/my-page?PID=1234

    (Because of a plugin on that page, for example). Then the PDF link generated is the same, and it loses (ignores) the all-important PID parameter in the URL. Without this parameter, the page displays incorrect (or in this case, blank) data, which results in the PDF page containing nothing in it! Arrghh!

    Any ideas or suggestions from the community? I'd really like to continue using this plugin, but I'd also be open to other plugins that do this correctly.

    Thanks!
    bruce

    http://wordpress.org/extend/plugins/wp-post-to-pdf/

  2. bbergman
    Member
    Posted 2 years ago #

    Update: I added some code to the plugin source, and that didn't really help. I think the URL isn't passed along further downstream (i.e., to tcPDF?). I'm still searching for a fix or a replacement plugin if this can't be fixed.

    thanks!
    bruce

  3. bbergman
    Member
    Posted 2 years ago #

    Hmm. Okay, maybe this is NOT the fault of this plugin. I've tried every one of the Top 25 PDF plugins (search for: pdf) and none of them work except for the ones that curl the web page and generate the PDF in the cloud. Those all work fine.

    This plugin still doesn't respect the URL parameters, but the code change for that is just 3-4 lines of PHP code. I can provide it if anyone wants it.

    That's not enough to make it work, however. I'm guessing that the tcPDF library doesn't handle things correctly, or there's something else beyond my grok going on. The plugin that I'm trying to print is the Participants Database plugin.

    If the developer ever reads this and wants any help to resolve this, I'm happy to help out in testing or applying patches. You can reach me via the account here.

    Thanks!
    bruce

  4. Neerav Dobaria
    Member
    Plugin Author

    Posted 2 years ago #

    Hi Bruce,

    It may sound rude!

    There are plenty of plugins available with WP, many use different URL parameters. Its not possible for me to make it work for all plugins out there.

    Besides, you don't even mentioned name of plugin which add PID parameter. I could not guess from your info.

    Regards,
    Neerav

  5. bbergman
    Member
    Posted 2 years ago #

    I did mention the other plugin (Participants Database). However, I do thank you for your time and energy in putting together this plugin.

    I will go find a different one to use.

    thanks,
    bruce

  6. BlogSelectividad
    Member
    Posted 1 year ago #

    Hello bbergman,

    Some days ago, I started a new thread in the support forum of this plugin because I found a problem with image url parsing. You can see it here:

    http://wordpress.org/support/topic/plugin-wp-post-to-pdf-url-image-parsing-problem

    Maybe my problem is similar than yours. You said that you have changed some lines of PHP code in order to solve your problem, could you provide to me these changes? I would appreciate your help.

    Thanks in advance.

  7. rscano
    Member
    Posted 1 year ago #

    I'm also interested to have this fix, due i've got a plugin that put shortcode inside the page but if the pdf plugin don't pass the URL parameters, isn't possible to use it as PDF printer :(

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic