JavaScript
0
Вклад в тег
$paged = 1;
$req_uri = array_reverse(explode('/', $_SERVER['REQUEST_URI']));
foreach ($req_uri as $value) {
if(is_numeric($value)) {
$paged = $value;
break;
}
}
$args = array (
'post_type' => 'post',
'post_status' => array( 'publish' ),
'posts_per_page' => '8',
'paged' => $paged
);