Support » Plugin: WP-Print » WP-Print incompatible with WPML (multilingual)

  • Hi everyone.

    First, thanks for a great plugin – WP-Print is simple and very effective!

    However, there are some issues when using WP-Print alongside WPML (the wordpress multilingual). In a WPML site, pages have URLs such as:

    In the first case, WP-Print simply appends the “/printpage/” suffix after the query, which obviously does not work. A better way would be to parse the permalink URL and append the WP-Print suffix to the path, and then reconstruct the URL.

    A second issue happens even in the second URL form, when you have a static front page for the site. In this case, WP-Print generates the link to the print page via an internal “_get_page_link”, instead of the standard “get_permalink” (line 118 of wp-print.php). WPML does not hook into that method, so you get an invalid, non-WPML URL. I am not sure why the plugin uses _get_page_link – are there good reasons for that?

    Anyway, I’m willing to help correct at least the first issue, but could some advise as to the second?

    I imagine these problems could break other plugins that also change the site’s URL structure, not just WPML.



Viewing 3 replies - 1 through 3 (of 3 total)
  • roji


    Hey, anyone still maintaining this plugin??



    I’ve just been running through the same problem and this is how I solved it : in wp-print.php (in wp-content > plugins > wp-print), search for the print_link function, replace
    $print_link = _get_page_link();
    $print_link = get_page_link();

    I didn’t find any problem to replace the function, but if there are, I’ll be glad to know them.



    Hi lorem_ipsum, and thanks for the suggestion… I’m hoping that the plugin maintainer will manifest themselves, as these are general problems that should be fixed in the plugin itself. It’s too bad so many wordpress plugins become orphans so quickly!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘WP-Print incompatible with WPML (multilingual)’ is closed to new replies.