fix bug to show post.
This commit is contained in:
parent
e33e226983
commit
ae9bfbe051
@ -209,13 +209,12 @@ function cbsonline_fix_category_pagination($query = [])
|
|||||||
{
|
{
|
||||||
if (isset($query['category_name']) && isset($query['page'])) {
|
if (isset($query['category_name']) && isset($query['page'])) {
|
||||||
if (preg_match('/^(?:category\/)?(.+)\/page$/', $query['category_name'], $matches)) {
|
if (preg_match('/^(?:category\/)?(.+)\/page$/', $query['category_name'], $matches)) {
|
||||||
$query['category_name'] = $matches[1];
|
$query['category_name'] = $matches[1].$query['page'];
|
||||||
}
|
unset($query['page']);
|
||||||
$query['category_name'] .= $query['page'];
|
if (isset($query['p'])) {
|
||||||
unset($query['page']);
|
$query['paged'] = $query['p'];
|
||||||
if (isset($query['p'])) {
|
unset($query['p']);
|
||||||
$query['paged'] = $query['p'];
|
}
|
||||||
unset($query['p']);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user