Forum


Replies: 1   Views: 2670
Override table style
Topic closed:
Please note this is an old forum thread. Information in this post may be out-to-date and/or erroneous.
Every phpdocx version includes new features and improvements. Previously unsupported features may have been added to newer releases, or past issues may have been corrected.
We encourage you to download the current phpdocx version and check the Documentation available.

Posted by admin  · 17-05-2017 - 08:35

Hello,

When you create a table from scratch, you can set dynamic aligment. The sample Core/addTable/sample_4.php included in all package illustrates how to do it.

If you need to change the table align of a template, you can use three approaches:

  • Use the block type replacement to remove the whole paragraph and replace the placeholder by a new WordFragment with the new align if you are using a Basic, Advanced or Premium license.
  • Use DOCXPath to replace the cell content by a new WordFragment with the new alignment if you are using an Advanced or Premium license.
  • Use DOCXCustomizer if you are using a Premium license.

Regards.