mvlcek
I18N Search plugin results throws many empty tags. Consider removing 'em by replacing in the searchresults.php file this code:
with
Sorry if wrong thread.
I18N Search plugin results throws many empty tags. Consider removing 'em by replacing in the searchresults.php file this code:
Code:
$link .= 'tags='.urlencode(@$_REQUEST['tags']).'&words='.urlencode(@$_REQUEST['words']);
$link .= '&search='.urlencode(@$_REQUEST['search']);
if (defined('PAGIFY_SEPARATOR')) {
preg_match('/^([^\?]*[^\?\/])(\/?(\?.*)?)$/', $link, $match);
$link = $match[1].PAGIFY_SEPARATOR.'%PAGE%'.@$match[2];
} else {
$link .= '&page=%PAGE%';
}
Code:
$arpar = [];
(isset($_REQUEST['tags']) ? $arpar[] = 'tags=' . urlencode(@$_REQUEST['tags']) : true);
(isset($_REQUEST['tags']) ? $arpar[] = 'words=' . urlencode(@$_REQUEST['words']) : true);
(isset($_REQUEST['tags']) ? $arpar[] = 'search=' . urlencode(@$_REQUEST['search']) : true);
if (defined('PAGIFY_SEPARATOR')) {
preg_match('/^([^\?]*[^\?\/])(\/?(\?.*)?)$/', $link, $match);
$link = $match[1].PAGIFY_SEPARATOR.'%PAGE%'.@$match[2];
} else {
$arpar[] = 'page=%PAGE%';
}
$link .= implode("&", $arpar);
Sorry if wrong thread.