In the original code snippet at line 65 the newline characters are translated into blanks. Not sure if that is having an effect on the output or not. But I am fairly sure that sending HTML markup tags to FPDF is not the best way to go.

When I have used FPDF, I have used it very differently from the way you are using it here. Instead of feeding it HTML, I have used the FPDF methods to directly place the text I want onto the FPDF object. The reasons for this are manifold. First, HTML is a markup language, not a formatting language. HTML has no inherent respect for absolute positioning (which is what is required on the printed page) and that is why we use CSS to adjust the presentation of the data. The PDF format is not concerned with CSS or markup, only with formatting and layout - which makes it the perfect tool for creating the printed page.

The advantages of direct placement through FPDF methods include the ability to structure the page exactly the way you want it - choosing fonts, placing text and images, etc. You just substitute PHP variables with the data you need and the results are predictable to within 1/100 inch.

0

Razzmataz73Author Commented: 2010-03-24

Passeur,
Can you tell me how to put this into FPDF using your suggestion?

ok,
I figured out how to embedd the pdf using the code bellow.
I have an accept/reject review page and when they hit accept it saves it to a database and creates the pdf (all working perfectly) now I want to post the new review (and an embedded pdf) on top of the old review dynamically.

So it is going to need to take the code bellow, paste it into an existing php page and then save the page.

I am thinking about doing this with a string replace, but this is my first time doing this.
This is what I have so far (it isn't working) I will continue to research but if someone has a fix that would be great.
:)