• Capobis

    (@ioweuiraosjfosj)


    I’m trying to edit the file ‘wp-post-to-pdf-enhanced.php’ to insert an external image into the PDF (the avatar of the user) but I get errors like “Unable to get the size of the image”.

    This is the code that should display the avatar:

    $current_user = wp_get_current_user();
      echo st_get_profile_avatar($current_user->ID,40);

    But what would be the right way of adding to the file “wp-post-to-pdf-enhanced.php”?

    Thanks in advanced.

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

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter Capobis

    (@ioweuiraosjfosj)

    Any help please? The only thing I need is to generate the PDF with the user logo.

    This code show the logo:

    $current_user = wp_get_current_user();
      echo st_get_profile_avatar($current_user->ID,40);

    But how can added correctly to the plugin code?

    Thanks in advanced.

    Plugin Author Lewis Rosenthal

    (@lewisr)

    Sorry. Offhand, I don’t have any good suggestions for you. I’ll add this to my enhancement list, though.

    You might want to review the documentation for the TCPDF class, as that’s what needs to be told how to render the image.

    Good luck

    Hey Capobis,

    Did you work this out?

    Many thanks,
    F

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Insert the user avatar (logo) in PDF’ is closed to new replies.