示例#1
0
function daoGetSettingType($key)
{
    $query = "SELECT settingstype FROM settings WHERE settingskey = '" . $key . "'";
    return getScalar($query);
}
示例#2
0
function countCommentsOnArticle($articleid)
{
    $query = "SELECT COUNT(articleid) FROM articles WHERE is_deleted IS NULL AND comment_to =" . $articleid . ";";
    $result = getScalar($query);
    return $result;
}