Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
library
uw_lib_refshelf
Commits
f0eabc42
Commit
f0eabc42
authored
Jan 12, 2018
by
Ganesharatnam
Browse files
modified for search
parent
408535b9
Changes
1
Hide whitespace changes
Inline
Side-by-side
uw_lib_refshelf.module
View file @
f0eabc42
...
...
@@ -538,8 +538,9 @@ function _keywordSearch($word, $data) {
if
(
!
empty
(
$word
)
&&
!
empty
(
$str
))
{
if
(
strlen
(
$str
)
>=
strlen
(
$word
))
{
$s_word
=
"/"
.
$word
.
"/i"
;
//$regEx = '\'(?!((<.*?)|(<a.*?)))(\b' . $word . '\b)(?!(([^<>]*?)>)|([^>]*?</a>))\'si';
if
(
preg_match
(
$s_word
,
$str
))
{
$regex
=
'\'(?!((<.*?)|(<a.*?)))(\b'
.
$word
.
'\b)(?!(([^<>]*?)>)|([^>]*?</a>))\'si'
;
//if (preg_match($s_word, $str)) {
if
(
preg_match
(
$regex
,
$str
))
{
return
TRUE
;
}
else
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment