在dompdf中创建复选框 [英] Creating checkboxes in dompdf

查看:59
本文介绍了在dompdf中创建复选框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在使用dompdf将HTML转换为PDF时,是否可以使用复选框元素(以及checked属性)?

Is it possible to use checkbox elements (along with the checked property) when converting HTML to PDF using dompdf?

我正在使用0.6.3 Beta,并且一些初步测试未证明是成功的:

I'm using 0.6.3 beta, and some initial tests are not proving successful:

<p>Checkboxes:
<p><input type=checkbox name=on checked> ON
<p><input type=checkbox name=off> OFF

结果:

Checkboxes:
ON
OFF

在dompdf 0.5.1和0.5.2.中确认了相同的行为.

The same behavior is confirmed in dompdf 0.5.1 and 0.5.2.

我正在使用复选框仅用于显示目的.在将数据传递回dompdf之前,将处理所有客户输入的数据.利益相关者对于他们要求PDF包含复选框的要求是坚定的(有些复选框处于选中状态,有些则不取决于预处理的用户输入).

I am using the checkboxes for display purposes only. Any client entered data is processed before passing data back to dompdf. The stakeholder is firm about their request for the PDF to contain checkboxes (some checked, some not depending on pre-processed user input).

dompdf是否能够处理复选框(和其他输入元素),如果可以的话,应该如何在源HTML中对其进行编码?

Is dompdf able to handle checkboxes (and other input elements), if so how should they be coded in the source HTML?

推荐答案

我提交了

I committed r500 today, which permits to display form elements.

您可以通过签出SVN中继来抓取它.

You can grab it by checking out the SVN trunk.

这篇关于在dompdf中创建复选框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆