0

我尝试在 php 中使用库 dompdf 生成 pdf 文件,但发现以下错误。

遇到 PHP 错误

Severity: Warning
Message: explode() expects parameter 2 to be string, array given
Filename: include/style.cls.php
Line Number: 1061

我试图调试并发现这个导致错误的数组

array
  'background_position' => 
    array
      0 => string '0%' (length=2)
      'x' => string '0%' (length=2)
      1 => string '0%' (length=2)
      'y' => string '0%' (length=2)
  'background' => string 'none' (length=4)

我的问题是如何修复这个错误,这个数组来自哪里?

感谢任何回应。

谢谢,弗兰斯

4

1 回答 1

0

您必须设置background_position为带有空格分隔符的字符串。在第 989 行查找类代码- 方法开始

于 2013-03-17T12:23:22.207 回答