WordPress Print This Section
Print This was unable to locate the section you requested. (3 posts)

  1. creationdesignstudio
    Posted 4 years ago #

    I love your plugin and it works really great, but only on one post. I have multiple posts I want to use the print option for, and it only works on one post and all the other posts when you press print give you this error:

    Print This was unable to locate the section you requested. Please contact the site administrator.

    The interesting thing is that when I'm editing the post and I say preview changes, it works just fine with all posts, but actually using them on the website, they stop working and give that error. Any suggestions? Thanks!


  2. Bryan Hoffman
    Posted 4 years ago #

    Chiming in that I'm getting a similar issue: http://kpcw.org/community/coupons/

  3. Bryan Hoffman
    Posted 4 years ago #

    Just a quick update on what my issue was, and how I hacked the plugin to get it to work...

    The site has a Coupons custom post type, and within each coupon I've added the [print_this] shortcode. I then have a page that displays each coupon.

    The very first post would print correctly, but the remaining ones would give the error @creagtiondesignstudio mentioned. The plugin seems to be able to mark each section with a printsec variable. When I click on the print button for each individual coupon the link is taken to the single post page for that coupon. Coupon #2 would then have a printsec=2 when there's only one section to print on that page... manually changing the variable in the url to 1 would allow the page to work correctly.

    I 'fixed' it by editing class-wp-print-this-plugin.php. On line 170, change:

    $print_this_link = get_permalink( $post->ID ) . '&printthis=1&printsect=' . $print_this_counter;


    $print_this_link = get_permalink( $post->ID ) . '?printthis=1&printsect=1';

    I don't like editing plugins like this, but it works for me now...

    ~ Bryan

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WordPress Print This Section
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic