两份PHP程序代码对比,大家认为其编程水平都怎么样?censor.class.php
功能:一个censor审核提交字符串的类(附加在DEDECMS里面)
两份不同的作品,同样的一种功能,大家评比一下~认为他们的水平如何?
如果你是主考官,你会如何选择?为什么?
涉及MySQL数据表:gk_info_censor
<br> mysql> desc gk_info_censor;<br> +-------------+----------------------+------+-----+---------+----------------+<br> | Field | Type | Null | Key | Default | Extra |<br> +-------------+----------------------+------+-----+---------+----------------+<br> | id | smallint(6) unsigned | NO | PRI | NULL | auto_increment |<br> | admin | varchar(15) | NO | | | |<br> | type | smallint(6) | NO | | 1 | |<br> | find | varchar(255) | NO | UNI | | |<br> | replacement | varchar(255) | NO | | | |<br> | extra | varchar(255) | NO | | | |<br> | count | int(11) | NO | | 0 | |<br> | updatetime | int(11) | NO | | NULL | |<br> | tids | mediumtext | NO | | NULL | |<br> | enable | tinyint(1) | NO | | -1 | |<br> +-------------+----------------------+------+-----+---------+----------------+ <div class="clear"> </div>