Skip to content

Commit 4fb9192

Browse files
Smart Search: utf8_strpos: Offset must be an integer
1 parent d63561a commit 4fb9192

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

components/com_finder/views/search/tmpl/default_result.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
// Calculate number of characters to display around the result
2020
$term_length = JString::strlen($this->query->input);
2121
$desc_length = $this->params->get('description_length', 255);
22-
$pad_length = $term_length < $desc_length ? floor(($desc_length - $term_length) / 2) : 0;
22+
$pad_length = $term_length < $desc_length ? (int) floor(($desc_length - $term_length) / 2) : 0;
2323

2424
// Find the position of the search term
2525
$pos = $term_length ? JString::strpos(JString::strtolower($this->result->description), JString::strtolower($this->query->input)) : false;

0 commit comments

Comments
 (0)