1

we are very interested in using your script but we are having some troubles with it.
using the example it gets an error. and of course with our HTML.
can you help us with the problem.

i send you the code we want to use for translating into pdf.

thank you very much.

tromb Fichier joint : notas.php

2

hi !
asques (./1) :
using the example it gets an error


what is the error ?
Ancien pseudo : lolo

3

Fatal error: Uncaught <span style="color: #AA0000; font-weight: bold;">ERROR n°4</span><br>
Fichero : /home/s020d938/public_html/intranet/notas/html2pdf/parsingHTML.class.php<br>
Línea : 99<br>
<br>
Código HTML no válido, las etiquetas no estan cerradas en el orden correcto.<br>Estado : <pre>Array ( [0] => page [1] => div [2] => table [3] => tr [4] => td [5] => span ) </pre><br>
<br>
HTML : ...run:yes'class=dades&gt;Fern&Atilde;&iexcl;ndez&lt;/td&gt; &lt;td class=xl6631821&gt;1. JUDO TERR... thrown in /home/s020d938/public_html/intranet/notas/html2pdf/parsingHTML.class.php on line 99


but i have checked all de body code and every tag is correctly closed.

thanx

4

Can anyone help me with my error?

in the first comment i have posted the code i want to convert to PDF, i cannot find the errors that don't allow me to use ur code.

thank you very much!!!

5

can you post here the html ?
Ancien pseudo : lolo

6

here u hav

tromb Fichier joint : notas.php

7

does anybody can help me?

8

your html and css code is not really clean... start from the beginning, by creating your HTML from your own hands... not with a tool like dreamweaver or others... and read the examples...
Ancien pseudo : lolo

9

i have found the problem, i have done the code again and now i can create th pdf but it's not exactly how it should be. The background picture is not shown and the boxes are not correctly marked. i'm posting an example so you can understand what i mean.
this is how it should be:
tromb Fichier joint : notasOK.pdf
this is how it is:
tromb Fichier joint : notasKO.pdf
and this is the code:
tromb Fichier joint : notas (1).php

where i'm getting wrong?

thank you very much for your help.

10

why do you put all your table on a div ?

about le borders : it is because border-collapse is enabled.

about le position on the page : try to use the marges on the <page> tag
Ancien pseudo : lolo

11

With your help i got almost everything but the <page> tag doesn't accept backtop='20mm' and the other properties it says error unespected L_NUMBER, well, I solved with the array in the constructor, now, i can't insert the background image, any idea?

how can i do to save the pdf in a folder in the server, i set the correct parameters to the folder.

thank you once more.

The new PDF auto generated:
tromb Fichier joint : notasAG.pdf

The new Code:
tromb Fichier joint : notas.php

12

about the image, try with a background-image on the table. look at the examples.

about saving the file on the server : look at the wiki : http://wiki.spipu.net/doku.php?id=html2pdf:en:v3:output

[nosmile]
Ancien pseudo : lolo

13

Thank you very much Spipou! it worked perfectly when i visualize in html but the image properties doesn't work and the image is not saved on the pdf.

i'm doing this:
<table border=0 cellpadding=0 cellspacing=0 width=895 style='border-collapse: separate;table-layout:fixed;width:672pt; background-image:url(\"logo/$logo\")'>
and works in html, not in pdf.

but if i do this:
<table border=0 cellpadding=0 cellspacing=0 width=895 style='border-collapse: separate;table-layout:fixed;width:672pt; background:url(\"logo/$logo\")'>

error:
Fatal error: Uncaught <span style="color: #AA0000; font-weight: bold;">ERROR n°6</span><br>Fichero : /home/s020d938/public_html/intranet/notas/html2pdf/html2pdf.class.php<br>Línea : 2545<br><br>Imposible cargar la imagen <b>"logo/judo.png"</b> thrown in /home/s020d938/public_html/intranet/notas/html2pdf/html2pdf.class.php on line 2545

if i do:

<table border=0 cellpadding=0 cellspacing=0 width=895 style='border-collapse: separate;table-layout:fixed;width:672pt; background:url(\"logo/$logo\"); background-position: center; background-repeat: no-repeat'>

i get the same error.

any idea?

thank you very much once more.

14

anybody knows why does it happen?

thank you

15

Have you tried with another image or with a simplest html ?
Ancien pseudo : lolo

16

I'd the same problem yesterday. For me ... the stuff was that I was testing a script in localhost but without images. Well, fors solve your problem, I think you can try to call images with absolute path.

Maibe, first, you can try to do this:
background:url(\"logo/img.png\");

and then
background:url(\"logo/$logo\");

In this way you are shure that $logo is correct. Are you shure that $logo has the value you expect?
--
skype: rastagnolo