Files
EasySoft-ZenTaoPMS/trunk/lib/front/tests/html_radio.php
2010-05-02 15:32:06 +00:00

30 lines
715 B
PHP
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#!/usr/bin/env php
<?php
/**
* 测试html的radio方法。
*
* 1. 正常情况。
* 2. 验证单个selectedItems是否正确。
* 3. 验证多个selectedItems是否正确。(没有一个选中。)
* 4. 验证attrib传递是否正确。
* 5. 验证options为空是否返回false。
*
* @author chunsheng.wang <chunsheng@cnezsoft.com>
* @version $Id$
*/
include '../front.class.php';
$options['a'] = 'texta';
$options['b'] = 'textb';
$options['c'] = 'textc';
echo html::radio('radio', $options);
echo html::radio('radio', $options, 'a');
echo html::radio('radio', $options, 'a,b');
echo html::radio('radio', $options, '', 'style="color:red"');
var_dump(html::radio('radio', array()));
<<<expect
html_radio.expect
expect
?>