See issue 3157: Fulltext is now disabled
This commit is contained in:
parent
82ebc673a0
commit
cec79ddf2b
3 changed files with 10 additions and 8 deletions
|
@ -574,9 +574,10 @@ function network_content(App $a, $update = 0) {
|
||||||
$sql_order = "`item`.`id`";
|
$sql_order = "`item`.`id`";
|
||||||
$order_mode = "id";
|
$order_mode = "id";
|
||||||
} else {
|
} else {
|
||||||
if (get_config('system','use_fulltext_engine'))
|
// Disabled until final decision what to do with this
|
||||||
$sql_extra = sprintf(" AND MATCH (`item`.`body`, `item`.`title`) AGAINST ('%s' in boolean mode) ", dbesc(protect_sprintf($search)));
|
//if (get_config('system','use_fulltext_engine'))
|
||||||
else
|
// $sql_extra = sprintf(" AND MATCH (`item`.`body`, `item`.`title`) AGAINST ('%s' in boolean mode) ", dbesc(protect_sprintf($search)));
|
||||||
|
//else
|
||||||
$sql_extra = sprintf(" AND `item`.`body` REGEXP '%s' ", dbesc(protect_sprintf(preg_quote($search))));
|
$sql_extra = sprintf(" AND `item`.`body` REGEXP '%s' ", dbesc(protect_sprintf(preg_quote($search))));
|
||||||
$sql_order = "`item`.`id`";
|
$sql_order = "`item`.`id`";
|
||||||
$order_mode = "id";
|
$order_mode = "id";
|
||||||
|
|
|
@ -203,11 +203,12 @@ function search_content(App $a) {
|
||||||
} else {
|
} else {
|
||||||
logger("Start fulltext search for '".$search."'", LOGGER_DEBUG);
|
logger("Start fulltext search for '".$search."'", LOGGER_DEBUG);
|
||||||
|
|
||||||
if (get_config('system','use_fulltext_engine')) {
|
// Disabled until finally is decided how to proceed with this
|
||||||
$sql_extra = sprintf(" AND MATCH (`item`.`body`, `item`.`title`) AGAINST ('%s' in boolean mode) ", dbesc(protect_sprintf($search)));
|
//if (get_config('system','use_fulltext_engine')) {
|
||||||
} else {
|
// $sql_extra = sprintf(" AND MATCH (`item`.`body`, `item`.`title`) AGAINST ('%s' in boolean mode) ", dbesc(protect_sprintf($search)));
|
||||||
|
//} else {
|
||||||
$sql_extra = sprintf(" AND `item`.`body` REGEXP '%s' ", dbesc(protect_sprintf(preg_quote($search))));
|
$sql_extra = sprintf(" AND `item`.`body` REGEXP '%s' ", dbesc(protect_sprintf(preg_quote($search))));
|
||||||
}
|
//}
|
||||||
|
|
||||||
$r = q("SELECT %s
|
$r = q("SELECT %s
|
||||||
FROM `item` %s
|
FROM `item` %s
|
||||||
|
|
|
@ -147,7 +147,7 @@
|
||||||
<div class="submit"><input type="submit" name="page_site" value="{{$submit|escape:'html'}}" /></div>
|
<div class="submit"><input type="submit" name="page_site" value="{{$submit|escape:'html'}}" /></div>
|
||||||
|
|
||||||
<h3>{{$performance}}</h3>
|
<h3>{{$performance}}</h3>
|
||||||
{{include file="field_checkbox.tpl" field=$use_fulltext_engine}}
|
<!-- {{include file="field_checkbox.tpl" field=$use_fulltext_engine}} -->
|
||||||
{{include file="field_checkbox.tpl" field=$only_tag_search}}
|
{{include file="field_checkbox.tpl" field=$only_tag_search}}
|
||||||
{{include file="field_input.tpl" field=$itemcache}}
|
{{include file="field_input.tpl" field=$itemcache}}
|
||||||
{{include file="field_input.tpl" field=$itemcache_duration}}
|
{{include file="field_input.tpl" field=$itemcache_duration}}
|
||||||
|
|
Loading…
Reference in a new issue