Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #38447

    I am using (evaluating) PD4ML 4.0.20 to replace our use of PD4ML v3. I am having issues loading images and external CSS files in a JSP file.

    Our structure:

    /WEB-INF/views/templates/report_template.jsp
    /styles/report_style.css
    /images/report_image.png

    In the past we’ve used the JSP standard library tags <c:url value=”/styles/report_style.css”/> with great success. This no longer seems to work with PD4ML v4.

    I’ve tried relative paths, such as:

    ../../../styles/report_style.css
    ../../../images/report_image.png

    which does not seem to work.

    Embedded styles work fine.

    I wanted to track down where PD4ML was trying to get the images from, so I added the following to the pd4ML:transform tag.

    debug=”true”

    This generated a 500 error. The partial stack trace is shown below.

    Stacktrace:] with root cause
    java.lang.NumberFormatException: For input string: “true”
    at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
    at java.lang.Integer.parseInt(Integer.java:580)
    at java.lang.Integer.parseInt(Integer.java:615)
    at com.pd4ml.taglib.PD4MLTransformerTag.setDebug(y:2448)

    Thoughts and solutions would be greatly appreciated.

    #38448

    Hi! Starting with PD4ML v4.0, the debug attribute requires a numeric value: a bitmask to enable certain aspects of logging. The value 255 enables a lot.

    For easier migration to v4 you can keep pd4ml_tl.jar from PD4ML v3 and keep your JSPs unchanged (debug=”true” will act as debug=”255″). PD4ML v4 JAR includes PD4ML v3 API wrapper, so it will translate PD4ML v3 API calls coming from pd4ml_tl.jar to the new v4 API.

    #38449

    Hi! Starting with PD4ML v4.0, the debug attribute requires a numeric value: a bitmask to enable certain aspects of logging. The value 255 enables a lot.

    For easier migration to v4 you can keep pd4ml_tl.jar from PD4ML v3 and keep your JSPs unchanged (debug=”true” will act as debug=”255″). PD4ML v4 JAR includes PD4ML v3 API wrapper, so it will translate PD4ML v3 API calls coming from pd4ml_tl.jar to the new v4 API.

    So where is this documented?

    Will including the pd4ml_tl.jar from pd4ml v3 allow us to use the new CSS / HTML / Accessibility features of v4?

    #38450

    So where is this documented?

    The taglib URL doc is https://pd4ml.com/taglibdoc/
    But as I see there is an inconsistence there with what I wrote above. I need to clarify that with the development.

    Will including the pd4ml_tl.jar from pd4ml v3 allow us to use the new CSS / HTML / Accessibility features of v4?

    Ah, no… PD4ML v3 API “knows” nothing about PDF/UA output option. But CSS/HTML new features are there.

    #38452

    Hi! Starting with PD4ML v4.0, the debug attribute requires a numeric value: a bitmask to enable certain aspects of logging. The value 255 enables a lot.

    For easier migration to v4 you can keep pd4ml_tl.jar from PD4ML v3 and keep your JSPs unchanged (debug=”true” will act as debug=”255″). PD4ML v4 JAR includes PD4ML v3 API wrapper, so it will translate PD4ML v3 API calls coming from pd4ml_tl.jar to the new v4 API.

    Just as a note: Setting debug=”255″ provides no debugging information when running under Tomcat (nothing in catalina.out or localhost). There are no errors when generating the PDF, but there is no output in the logs. I’ll try running Tomcat with debug mode to see if that helps.

    #38453

    Hi! Starting with PD4ML v4.0, the debug attribute requires a numeric value: a bitmask to enable certain aspects of logging. The value 255 enables a lot.

    For easier migration to v4 you can keep pd4ml_tl.jar from PD4ML v3 and keep your JSPs unchanged (debug=”true” will act as debug=”255″). PD4ML v4 JAR includes PD4ML v3 API wrapper, so it will translate PD4ML v3 API calls coming from pd4ml_tl.jar to the new v4 API.

    Just as a note: Setting debug=”255″ provides no debugging information when running under Tomcat (nothing in catalina.out or localhost). There are no errors when generating the PDF, but there is no output in the logs. I’ll try running Tomcat with debug mode to see if that helps.

    I’ve confirmed that running Tomcat under DEBUG mode does generate the debugging information. I am now parsing through that to figure out why styles and images are not being loaded. However that’s an issue for another thread.

    Thanks for the pointers.

Viewing 6 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic.