|
geoffc
5 posts Location: n.a. |
03.02.2012 13:21Problem with Dscussions search pluginAchim
I have had this problem for a while but only just tracked it down.
If you have the discussions search plugin enabled (default setting when component is installed) and you perform a search with an empty string, you end up with a lot of messages about 'Warning: mb_strpos() [function.mb-strpos]: Empty delimiter in /share/MD0_DATA/Web/Joomla/libraries/phputf8/mbstring/core.php on line 44
' and the resulting display shows forum entries with every character separated by a space.
Looking at the code I suspect that what is needed is some code like the following after line 56.
$text = trim($text);
if ($text == '') {
return array();
}
This resolves the problem and also lets the Discussions search module work the same as the other search plugins in the system (Content, Contacts etc.), which do not return any results if an empty string is in the search.
This problem is also in Discussions 1.4 and may have been there for some time. After all its not sensible to search for an empty string.
Regards
Geoff
|
|
|
|
savio
1 post Location: n.a. |
24.02.2012 22:08Re: Problem with Dscussions search pluginHi Achim,
I must say first your component is marvelous. Easy to install and use just out of the box.
After reading this thread, I do a test on my site and find something that I must report.
I login as registered user and create two testing messages in Discussions.
I logout.
I press enter at the search box with empty string. The two testing messages are displayed!
It could be a security issue because this messages should not be visible by public.
Regards,
Savio
Edited by savio - 24.02.2012 22:11
|
|
|
|
yziner
1 post Location: n.a. |
28.04.2012 09:54Re: Problem with Dscussions search pluginalso have the same problem + with hebrew i get ???????? marks instead of text.
|
|
|