';
} catch (CoreException $e) {
echo $e->showTrace();
}
echo '
';
if (User::isAuthorized()) {
echo str_replace('
getAllUserData(), 'Информация о пользователе'));
}
//echo str_replace('query('select count(*) as count from d_posts where post_type="post" and post_status="publish"')[0]['count'];
Pagination::execute($_REQUEST['page'], $count, 3);
$limit = Pagination::getLimit();
$arPosts = (DB::getInstance())->query('select * from d_posts where post_type="post" and post_status="publish" order by id desc limit ' . $limit);
$arResult = [];
foreach($arPosts as $post) {
$arResult[$post['ID']] = [
'title' => $post['post_title'],
'postname' => $post['post_name'],
'date' => $post['post_date'],
'userId' => $post['post_author'],
'userName' => (new User((int)$post['post_author']))->getName()
];
}
echo '';
echo str_replace('