【发布时间】:2012-08-17 02:56:14
【问题描述】:
对不起我的英语。
我有用于生成 HTML 表单的 PHP 类:
class Html_ElementInput extends Html_Element
{
public function __construct($type=null)
{
parent::__construct();
$this->attrs = array
(
'type' => array('text', 'password', 'checkbox', 'radio', 'submit', 'reset', 'file', 'hidden', 'image', 'button'),
'name' => 'CDATA',
'value' => 'CDATA',
'checked' => array('checked'),
'disabled' => array('disabled'),
'readonly' => array('readonly'),
'size' => 'Number',
'maxlength' => 'Number',
// ......
这种格式是模拟 SGML-DTD 描述 xHTML - http://economist.rudn.ru/files/web-studio/docs/html/xhtml/xhtml_1.0/xhtml1-transitional_dtd.txt
我想改变他们基于 HTML5 的类,但是没有 SGML-HTML5 规范的描述。
我是否正确理解 SGML-HTML5 描述不会?
【问题讨论】:
-
所以您的问题与有关 HTML5 规范的文档有关?
-
是的。我想看到 SGML 类型规范 HTML5,如 economist.rudn.ru/files/web-studio/docs/html/xhtml/xhtml_1.0/…,但 w3c.org 上的规范 HTML5 是另一种格式,我不明白它们。
标签: php html dtd specifications