0

I am using Codeplex library for converting php/html to docx.. I just want to know how can i add some spaces/tabs/margin before paragraph (

tag) . Here is the sample code i am using:

$html_body = '<html><body>';
$html_body .= $paragraph['opener'] ? $paragraph['opener'] : '';
$html_body .= '</body></html>';
$html_dom->load($html_body, true, false);

"$paragraph['opener']" contain a paragraph like

bla..bla.bla..

Actually i want to start my paragraph after some spaces/tabs.Is it possible?

Thanks in advance

  • I want to add some spacing/tab before paragraph. – user3756907 Jan 23 '15 at 13:51
  • Thanks.I just want to know relevant answer..Do you have any idea about that.. – user3756907 Jan 23 '15 at 14:45
  • Have you read through the examples provided with the library ? Also, the Codeplex project seems abandoned and another, actively maintained library called [PHPWord is on Github](https://github.com/PHPOffice/PHPWord), I'm not sure if that's the same one but I suggest you use the actively maintained one. They have [examples](https://github.com/PHPOffice/PHPWord/blob/3f136501b3dfea94766a704e17782c8a942a7b9b/samples/Sample_03_Sections.php) with sections having a defined margin, maybe that's what you want. –  Jan 23 '15 at 14:51
  • Hi Andre, I have also checked the above urls you provided me,this is not what i exactly want.Actually i want to add styling in

    tag that are populating dynamically(through database).Is it possible to add external/internal style for

    .

    – user3756907 Jan 29 '15 at 10:49

0 Answers0