better search split for bad URL
This commit is contained in:
parent
b1f8cda044
commit
4908f533f3
@ -227,7 +227,12 @@ class pubSaba
|
|||||||
self::getPostsParams($p);
|
self::getPostsParams($p);
|
||||||
|
|
||||||
$OR = [];
|
$OR = [];
|
||||||
foreach (explode(',', $p['search']) as $sentence) {
|
# decoupe un peu plus la recherche
|
||||||
|
$splits = preg_split("#[\s//,-_]+#", $p['search']);
|
||||||
|
if (!$splits) {
|
||||||
|
$splits = explode(',', $p['search']);
|
||||||
|
}
|
||||||
|
foreach ($splits as $sentence) {
|
||||||
$AND = [];
|
$AND = [];
|
||||||
$words = text::splitWords($sentence);
|
$words = text::splitWords($sentence);
|
||||||
foreach ($words as $word) {
|
foreach ($words as $word) {
|
||||||
|
Loading…
Reference in New Issue
Block a user