php - phpword中具有动态行数的表
问题描述
是否可以创建具有动态行的表?
我需要创建一个基于数组的表,但我不知道启动时数组的大小。
我看到了这样的事情:
$templateProcessor = new \PhpOffice\PhpWord\TemplateProcessor($myfqfilenamehere);
$tags = $templateProcessor->getVariables();
foreach($tags as $tag){
$templateProcessor->setValue($tag, "a value here");
}
但我不知道它是否是我需要的。
解决方案
推荐阅读
- c# - Windows 服务无法访问网络位置 (UNC) 路径
- node.js - Node.js - Firebase 导入返回在 Raspberry Pi 零上运行的非法指令
- python - Tensorflow 线性回归不收敛到正确值
- c++ - 反转字符串中单词的位置而不改变 O(1) 空间限制中特殊字符的顺序
- hive - Hive Bucket 上的最大功能
- asp.net-core - 在 Google Cloud Shell 中构建 .NET Core 2.1 应用程序失败
- excel - 如何在 vba 代码中调用用户定义的函数
- sql - SQL 来跟踪客户的旅程
- javascript - 为什么我要使用 RxJS 的 interval() 或 timer() 轮询而不是 window.setInterval()?
- batch-file - 如何将命令更改为您自己的命令