本文整理汇总了PHP中newznab\db\Settings::unix_timestamp_column方法的典型用法代码示例。如果您正苦于以下问题:PHP Settings::unix_timestamp_column方法的具体用法?PHP Settings::unix_timestamp_column怎么用?PHP Settings::unix_timestamp_column使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类newznab\db\Settings
的用法示例。
在下文中一共展示了Settings::unix_timestamp_column方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: postAll
/**
* Post all new comments to usenet.
*/
protected function postAll()
{
// Get all comments that we have not posted yet.
$newComments = $this->pdo->query(sprintf('SELECT rc.text, rc.id, %s, u.username, r.nzb_guid
FROM releasecomment rc
INNER JOIN users u ON rc.userid = u.id
INNER JOIN releases r on rc.releaseid = r.id
WHERE (rc.shared = 0 or issynced = 1) LIMIT %d', $this->pdo->unix_timestamp_column('rc.createddate'), $this->siteSettings['max_push']));
// Check if we have any comments to push.
if (count($newComments) === 0) {
return;
}
echo '(Sharing) Starting to upload comments.' . PHP_EOL;
// Loop over the comments.
foreach ($newComments as $comment) {
$this->postComment($comment);
}
echo PHP_EOL . '(Sharing) Finished uploading comments.' . PHP_EOL;
}