• Plugin Author Lewis Rosenthal

    (@lewisr)


    Restarting this thread, as our formatting was thrown off by posting CSS snippets. πŸ™

    Sorry for the slow response, Ellyn; have had my head in some work which does not seem to be letting up… (Yes, work is good; it just makes stuff like this more difficult!)

    Some items, in order:

    Do you happen to have a list of supported TCPDF CSS? I can’t seem to find anything in my searches, and it’s like trying to find a needle in a haystack and testing to see what works.

    Unfortunately, no, I do not. I do know that from the changelog, we have picked up text transforms since 6.0.043. The latest development build of the plugin includes TCPDF 6.0.062 which is current as of the date I uploaded that build (FWIW).

    Just for the heck of it, I tried to include an @import url(“…/style.css”) without any success. Have you tried that? It would be an easier way than copy/paste.

    Agreed, that it would be good to figure out a way to support this, and no, I have not tried (though I am not surprised that it did not work). That said, thinking on it now, I should be able to make this happen (you may recall that we talked about using external stylesheets when we started discussing the whole CSS feature). Again, this is no guaranty that TCPDF will obey, but it would prove less tedious than entering all of that code again (and a shortcode could be used to override the admin setting).

    It appears that what can be done with CSS is very limited with TCPDF.

    πŸ˜‰

    Can you tell me where it is going to look for images?

    This is defined in tcpdf/config/tcpdf_config.php and is set to '' (hmmm…). K_PATH_MAIN is set to WPPTOPDFENH_PATH.'/tcpdf/' so you might want to try (for now) using that directory (the tcpdf directory under the plugin – for everyone’s edification), and I’ll see what happens by setting K_PATH_IMAGES to something more useful, such as WP_CONTENT_DIR . '/uploads/' as a default, and adding an option for that in the admin UI.

    Also, it appears that the fonts configured in the settings are being applied after the CSS. Can you please verify?

    I’ll look later and give you something more definitive. I believe that TCPDF prioritizes HTML over CSS. Are you finding that your CSS for the font size (in your example style tag) is being overwritten or ignored, or is there some other font issue happening?

    Thanks so much for all of this. Sorry you’re still having so many issues, but your testing is invaluable (I can’t make it better if I don’t know what’s broken!).

    Cheers

    Lewis

    https://wordpress.org/plugins/wp-post-to-pdf-enhanced/

Viewing 6 replies - 16 through 21 (of 21 total)
  • I still can’t get the trunk build to work. Possibly I am missing some files? Here is what I downloaded from Subversion repository:
    884921 wp-post-to-pdf-enhanced\asset\css\admin.css
    884921 wp-post-to-pdf-enhanced\readme.txt
    884921 wp-post-to-pdf-enhanced\wp-post-to-pdf-enhanced.php
    882045 wp-post-to-pdf-enhanced\wpptopdfenh_header.php
    884921 wp-post-to-pdf-enhanced\wpptopdfenh_options.php
    882045 wp-post-to-pdf-enhanced\wpptopdfenh_shortcodes.php

    Plugin Author Lewis Rosenthal

    (@lewisr)

    You really need to download the whole zip, as the TCPDF class has changed.

    If you go here, and click on Development Version under Other Versions, Ellyn, you should get the full zip of the latest trunk build. Then, install that from the Plugins page in your admin area.

    You may already have the latest TCPDF as provided with the trunk build, but check the config file under tcpdf/config. TCPDF is funny; if something is amiss in the config (either because the config is broken or because I have moved something into the db), it may stubbornly refuse to output anything (it will throw an error if so configured, but again, that’s not by default).

    Try the full download and see what you get.

    Good luck!

    Lewis

    I kept missing that link and was manually downloading the files. Many thanks. I had a working for a moment, but seemed to do something that I know get the http://dslocks-hoc.pitlarson.com/demo/?format=pdf with no PDF. I’ve had this before, and just need to figure out what I did wrong. I will keep you posted.

    Hi Lewis,

    I decided to take a different approach with the list bullet images. Rather than do them as lists, I am now doing them as tables with images. It is not the most elegant solution, but I think it will get me what I need. I get the impression that the TCPDF limitations and the need for various lists was going to be too much for the short term.

    I never managed to get the development version working beyond the first time I tried it. That was after testing on another site also. I think I will wait until you have some time to do more on it.

    And also, the issue with two instances of the plugin showing up in the plugin list seemed to resolve itself on both sites also.

    You can go ahead and close this out now.

    I was able to get the development version 1.1.0b20140331 working. The problem seems to be if I selected a Header Logo Image. I tried it with the default logo supplied and my own logo with the same results.

    I also got the setLIsymbol working, but only when it is a jpg file. When I tried it as a png it did not work. It is also interesting to note that it seems to replace ordered list items “ol” with the image also.

    Plugin Author Lewis Rosenthal

    (@lewisr)

    Hi, Ellyn…

    Apologies for the extremely late follow-up. Besides the usual demands of work and family, I lost a dear friend last week (more on that on my blog). So, now I’m even farther behind than I had been.

    So let me just clarify:

    1. Header Logo – Not working at all, or working when no list item image added?
    2. setLIsymbol – jpg works but png does not. Did the png have an alpha channel or no? I’ll need to review the TCPDF docs to see exactly what is supposed to be replaced…checking… Docs say:

      Set the default bullet to be used as LI bullet symbol

      So, it sounds like we’re not getting exactly what we want. Please confirm.

    Thanks for following up!

    Lewis

Viewing 6 replies - 16 through 21 (of 21 total)
  • The topic ‘Include a print CSS file? (restarted thread)’ is closed to new replies.