Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #26761

    I have a webapp in a directory called PRC. In the PRC/Pages/test.jsp file, I have a line like this:

    <img alt="Delete This Assignment" align="top" src="/Common/Images/icon_delete.gif" />

    It displays fine on the HTML page, but when it’s converted to PDF, the image is missing. I’m assuming PD4ML is looking for that image in the PRC context and not the context called Common. How can I make it find the image in the other context?

    I have other images on the same page like:

    <img src="/PRC/Images/audit.png" border="0" alt="Click to view audit data." />

    And that shows up fine when I convert the page to PDF. I need PD4ML to handle images from multiple contexts in one page.

    I’m using the JSTL (JSP taglib) tags and not java/servlet code to convert the page to PDF.

    #29086

    PD4ML offers 2 API methods, which help to resolve web paths and load the resources: pd4ml.useServletContext() and pd4ml.useHttpRequest().

    (PD4ML taglib implicitly triggers pd4ml.useServletContext())

    If none of the methods help, the only solution is to extend the URIs from /Common/Images/icon_delete.gif to http://localhost/Common/Images/icon_delete.gif.

    In JSP context there is a special PD4ML custom tag intended for automatic extending of local to full URLs:
    http://pd4ml.com/taglib/pd4ml/fix_base_path.html

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

The forum ‘HTML/CSS rendering issues’ is closed to new topics and replies.