Contract creation

Hello,

I’m trying to create a PDF report that would serve as a contract for training.
I do not want a background image but only text.
I would need to display in my PDF paragraphs mixing fields and text as follows:
The formation of $ cell_name will take place on $ cell_date …

Except that $ cell_name can have a variable length and I want it to look like a sentence without unnecessary space.

I’m trying to create a varaible that I would post in the PDF but I can not do it.

Do you have a track?
Thank you

Create your document as a html text, use variables that can be replaced, i.e. $cell_name. Then upon creation time generate your html by replacing the $variables and call htmltopdf function.