Forum Replies Created
-
AuthorPosts
-
in reply to: Is JavaScript supported? April 9, 2010 at 19:36#27949
PD4ML does not support JavaScript
in reply to: uncorrect size for image April 9, 2010 at 19:50#27814And again: the document HTML source and resulting PDF would help to answer your question.
in reply to: HTML/CSS rendering issues April 10, 2010 at 07:23#26367Hi,
Recently i found this interesting tool. I want to generate a pdf which will consist of several pages. In each and every page we should be having a header and footer of a table row with the applied css on that.
the header would be
in reply to: HTML/CSS rendering issues April 12, 2010 at 15:11#26369Hi!
I’m trying to use pd4ml with tinyMce, but I have a lot of problem with math formulas, because the images of these formulas are too big.
I solve this problem with actual pdf generator (no pd4ml) with “zoom” parameter, but it doesn’t work in PD4ML.
Why?
How can I solve this? If I use % or em size in width or in height, results are various and depend from the size of formula.
Thanks
in reply to: zoom property April 12, 2010 at 15:15#27962Please attach a sample HTML and its resulting PDF – it would help a lot to analyze the issue and to provide you with a hint or a workaround.
in reply to: HTML/CSS rendering issues April 12, 2010 at 16:26#26368Hello,
I am doing some test with absolute positioning inside relative divs. Something like this
outer div 1inner-1inner-2outer div 2inner-1inner-2On the HTML each div is rendered one after the other and the inner divs are displayed INSIDE their outer divs.
Here is the sample html source code that I am trying to render with pd4ml.
<br /> <html><br /> <head><br /> <style type="text/css"><br /> h2 {<br /> page-break-after: always;<br /> }<br /> </style><br /> <jsp:include page="../../includes/head.jsp" /><br /> </head><br /> <body><br /> <center><br /> <div style=" background-color: aqua; width:100px; border-color: black; height:150px; border-width: 3px; border-style: solid;" ><br /> <div style="background-color: green; ">CONTRACHEQUE 1</div><br /> <div style="position: relative; border-color: red; border-width: 3px; border-style: solid;"><br /> <div style=" position: absolute; left: 0; top: 0; border-color: maroon; border-width: 3px; border-style: solid;"><br /> div absolute da imagem<br /> </div><br /> <div style="background-color: BLUE; position: absolute; left: 0; top: 0; border-color: yellow; border-width: 3px; border-style: solid;"><br /> <div id="destinatario" class="destinatario" ><br /> <p class="textoVerso">MARCOS URATA</p><br /> <p class="textoVerso">ENDERECO</p><br /> </div><br /> </div><br /> </div><br /> </div><br /> <h2> </h2><br /> <div style=" margin-top:5px; background-color: black; width:100px; height:150px; border-color: green; border-width: 3px; border-style: solid;"><br /> <div style="background-color: yellow; ">CONTRACHEQUE 2</div><br /> <div style="position: relative; border-color: red; border-width: 3px; border-style: solid;"><br /> <div style=" position: absolute; left: 0; top: 0; border-color: maroon; border-width: 3px; border-style: solid;"><br /> div absolute da imagem<br /> </div><br /> <div style="background-color: yellow; position: absolute; left: 0; top: 0;border-color: yellow; border-width: 3px; border-style: solid;"><br /> <div id="destinatario" class="destinatario" ><br /> <p class="textoVerso">MARCOS URATA</p><br /> <p class="textoVerso">ENDERECO</p><br /> </div><br /> </div><br /> </div><br /> </div><br /> <h2> </h2><br /> <div style="margin-top:5px; background-color: lime; width:100px; height:150px; border-color:fuchsia; border-width: 3px; border-style: solid;"><br /> <div style="background-color: silver; ">CONTRACHEQUE 3</div><br /> <div style="position: relative; border-color: red; border-width: 3px; border-style: solid;"><br /> <div style=" position: absolute; left: 0; top: 0; border-color: maroon; border-width: 3px; border-style: solid;"><br /> div absolute da imagem<br /> </div><br /> <div style="background-color: silver; position: absolute; left: 0; top: 0; border-color: yellow; border-width: 3px; border-style: solid;"><br /> <div id="destinatario" class="destinatario" ><br /> <p class="textoVerso">MARCOS URATA</p><br /> <p class="textoVerso">ENDERECO</p><br /> </div><br /> </div><br /> </div><br /> </div><br /> </center><br /> </body><br /> <br /> </html><br />
And the resulting pdf generated by pd4ml:
in reply to: uncorrect size for image April 12, 2010 at 16:28#27815How do I attach files to the message?
in reply to: CSS div positioning bug April 12, 2010 at 16:37#27954Hello,
I am doing some test with absolute positioning inside relative divs. Something like this
outer div 1inner-1inner-2outer div 2inner-1inner-2On the HTML each div is rendered one after the other and the inner divs are displayed INSIDE their outer divs.
Here is the sample html source code that I am trying to render with pd4ml.
[attachment=C:pd4ml.jpg][/attachment]<br /> <html><br /> <head><br /> <style type="text/css"><br /> h2 {<br /> page-break-after: always;<br /> }<br /> </style><br /> <jsp:include page="../../includes/head.jsp" /><br /> </head><br /> <body><br /> <center><br /> <div style=" background-color: aqua; width:100px; border-color: black; height:150px; border-width: 3px; border-style: solid;" ><br /> <div style="background-color: green; ">CONTRACHEQUE 1</div><br /> <div style="position: relative; border-color: red; border-width: 3px; border-style: solid;"><br /> <div style=" position: absolute; left: 0; top: 0; border-color: maroon; border-width: 3px; border-style: solid;"><br /> div absolute da imagem<br /> </div><br /> <div style="background-color: BLUE; position: absolute; left: 0; top: 0; border-color: yellow; border-width: 3px; border-style: solid;"><br /> <div id="destinatario" class="destinatario" ><br /> <p class="textoVerso">MARCOS URATA</p><br /> <p class="textoVerso">ENDERECO</p><br /> </div><br /> </div><br /> </div><br /> </div><br /> <h2> </h2><br /> <div style=" margin-top:5px; background-color: black; width:100px; height:150px; border-color: green; border-width: 3px; border-style: solid;"><br /> <div style="background-color: yellow; ">CONTRACHEQUE 2</div><br /> <div style="position: relative; border-color: red; border-width: 3px; border-style: solid;"><br /> <div style=" position: absolute; left: 0; top: 0; border-color: maroon; border-width: 3px; border-style: solid;"><br /> div absolute da imagem<br /> </div><br /> <div style="background-color: yellow; position: absolute; left: 0; top: 0;border-color: yellow; border-width: 3px; border-style: solid;"><br /> <div id="destinatario" class="destinatario" ><br /> <p class="textoVerso">MARCOS URATA</p><br /> <p class="textoVerso">ENDERECO</p><br /> </div><br /> </div><br /> </div><br /> </div><br /> <h2> </h2><br /> <div style="margin-top:5px; background-color: lime; width:100px; height:150px; border-color:fuchsia; border-width: 3px; border-style: solid;"><br /> <div style="background-color: silver; ">CONTRACHEQUE 3</div><br /> <div style="position: relative; border-color: red; border-width: 3px; border-style: solid;"><br /> <div style=" position: absolute; left: 0; top: 0; border-color: maroon; border-width: 3px; border-style: solid;"><br /> div absolute da imagem<br /> </div><br /> <div style="background-color: silver; position: absolute; left: 0; top: 0; border-color: yellow; border-width: 3px; border-style: solid;"><br /> <div id="destinatario" class="destinatario" ><br /> <p class="textoVerso">MARCOS URATA</p><br /> <p class="textoVerso">ENDERECO</p><br /> </div><br /> </div><br /> </div><br /> </div><br /> </center><br /> </body><br /> <br /> </html><br />
And the resulting pdf generated by pd4ml:
[attachment=C:pd4ml.pdf][/attachment]in reply to: uncorrect size for image April 12, 2010 at 16:57#27816pack them to a zip.
below the message text field, there is “choose file” and “add the file” buttons to add a message attachment.
in reply to: CSS div positioning bug April 12, 2010 at 17:17#27955Unfortunately it did not attach your document to the message. But I guess the document absolute positioning suffers from the explicit page breaks.
Starting with v360fx1b1 PD4ML has 2 absolute positioning modes: document- and page-centric.
You may switch to another mode with
-Dpd4ml.absolute.address.space=document
JVM parameter, PD4ML API call
[language=java:ilwg5xsw]Map m = new HashMap();
m.put(PD4Constants.PD4ML_ABSOLUTE_ADDRESS_SPACE, “document”);
pd4ml.setDynamicParams(m);[/language:ilwg5xsw]or with custom JSP tag, nested to
[language=xml:ilwg5xsw]
As a result you’ll get a document where absolute positioned blocks match relatively positioned blocks. But PD4ML also requires you explicitly define block dimensions.
in reply to: HTML to PDF conversion April 12, 2010 at 17:23#27939Hmm… I tried the URL with GUI tool
java -jar pd4ml_demo.jar
and got it converted. See attached.What kind of conversion problems do you experience?
in reply to: CSS div positioning bug April 12, 2010 at 17:32#27956Thank you for the quick reply.
I tried the parameter setting configuration, but it still did not work.
There is no “choose file” and “add the file” buttons to add a message attachment, so I am pasting below the source code of the jsp. If there is another way to send you the attachment files, I will be glad to send.
<%@ taglib uri="/WEB-INF/pd4ml.tld" prefix="pd4ml" %><%@taglib uri="http://java.sun.com/jstl/core_rt" prefix="c" %><%@page contentType="application/pdf" %><%response.setHeader("Cache-Control","no-cache"); //HTTP 1.1 response.setHeader("Pragma","no-cache"); //HTTP 1.0 response.setDateHeader ("Expires", 0); //prevents caching at the proxy server %>
CONTRACHEQUE 1div absolute da imagemMARCOS URATA
ENDERECO
CONTRACHEQUE 2div absolute da imagemMARCOS URATA
ENDERECO
CONTRACHEQUE 3div absolute da imagemMARCOS URATA
ENDERECO
in reply to: CSS div positioning bug April 12, 2010 at 17:41#27957Do you use PD4ML v360 or v360fx1b1? It is important.
You may send the file by email to support pd4ml.com
in reply to: CSS div positioning bug April 12, 2010 at 17:50in reply to: CSS div positioning bug April 12, 2010 at 17:55#27959As I see from the PDF document metadata you use v360, which does not “understand” the configuration switches I described. Please give a try to v360fx1b1.
But again: in order to get identical layouts, you need to explicitly specify block heights and widths.
AuthorPosts