I've seen that I can add HTML to a variable using the code shown here:
http://www.phpdocx.com/blog-news/adding-html-template-variable-phpdocx
I've also seen that I can replace several variables to build a table like shown here:
http://www.phpdocx.com/blog-news/how-generate-dynamical-table-phpdocx-word-template
These are great things but I wasn't able to combine them. What we'd like to achieve is to render this variable (note the b-tag in the second array):
$docx->addTemplateVariable(
array(
array(
'NAME' => 'Product A',
'WEIGHT' => '10',
'PRICE' => '5',
),
array(
'NAME' => '<b>Product B</b>',
'WEIGHT' => '20',
'PRICE' => '30',
),
), 'table', $settings
);
Any ideas on how we can achieve this?