【发布时间】:2009-08-06 12:30:43
【问题描述】:
我的表单中有以下私有方法:
function _verifywebsite ($id) {
$row = $this->websites->fetchRow("id=$id");
$row->verified_date = $this->_get_date(); // this is the line in question
$row->save();
}
我假设 $row 要求我以正确的日期格式输入日期作为字符串值。
但是如果我想包含一些 SQL 函数,比如 NOW(),我可以将它分配给 $row->verified_date 以某种方式或违反最佳实践?
【问题讨论】:
标签: php sql zend-framework