Why wont my CB search produce proper results?

13 years 11 months ago #130857 by jakobe75
Okay.....

another question


my Joomla search performs a one word search and brings up the profiles just fine.


index.php?option=com_search&view=search

I am using the CB advanced search Plugin v 1.0

I can type in "Sporting Goods"
Iget good results as long as that phrase appears in the profile.

- the username
- the profile description field
- profile keyword text fields

almost anywhere that those words appear.
so it is indeed searching the whole profile.


now this search works extremely well it seems.
why doesnt CB userlist searching work the same way?

and do you have any suggestions on making it work in this fashion?

Post edited by: jakobe75, at: 2010/04/21 18:30

Please Log in to join the conversation.

13 years 11 months ago #130888 by jakobe75
I have just purchased The CB Advanced Search COMPONENT.

Found it here:
extensions.joomla.org/extensions/extension-specific/community-builder-extensions/community-builder-search/10771

cost about $32us

This installs very easily and performs searches quickly. It also displays avatars with the results. YAY!

It has a default display box called "Keywords"
it searches almost every area of your searchable fields.

I had the best overall results when searching with this component.


However....it has a few drawbacks...well several drawbacks actually.

1. The cost.. for $30+ I expected a little more options, but I knew what I was getting into when I bought it...feels like a waste of money now as I cannot use it.

2. Results are displayed in one giant long list, like most of Joomla and CB's results..there is no "Grid" option, so a ton of white space will appear on the page.

3. You can select which fields you want displayed on the search form...however to effectively display a user you need a handful of fields such as name, city, state etc. Then multiply these by the different user types you may have..so soon you have a search form with 18 fields and only 6 of them filled with data as the other 12 are blank because they are for profile data you weren't searching or is not available for that user type.

4. There is no way to make a "userlist" or a search category.

example:
Search form #1..contains fields:
cb_username
cb_clubcity
cb_clubtype

Search from #2..contains fields:
cb_username
cb_bizcity
cb_biztype

Resulting in: Menu item Search#1 points to: Search form #1



5. No module. Since it doesnt tie directly in with cb lists, this com should come with a module
(although you can use a component loader to get it to display but then the pages become all wonky)

6. no demo, you only get screens

7. no forum

8. really no options except for adding and displaying fields

9. upon install my searches were performed properly but my profile itemIDs are all messed up..rendering it unusable.


The setup method is quite simple,
- install
- add the cb_fields you want to search in the component.
- make a menu item to the component
- click and enjoy


Just a few small minor things could make this a killer CB addon.
1. grid view
2. better field display/control
3. search categories
4. cb userlist integration


If you are looking for a flexible no nonsense search that produces search results as you would expect. Then this is for you.


I sent a review to the developer and on the Joomla Extensions site with my suggestions and bugs.

Please Log in to join the conversation.

13 years 11 months ago #130993 by krileon
Am not sure what more to advise; we are aware that the userlist needs a re-haul. We've acknowledged this in your other threads. Yes we are going to redo it to be more intuitive and have better search features. Soon? No. We've this planned for CB 2.0, sorry. It is simply too big of a feature to add in a minor release.

I still have yet to understand the issue because I merely can not duplicate your results. Unless ALL users have "rick" or "sporting goods" in the field then they shouldn't show up. It's working perfectly fine on all my local and live tests (can try my personal site if you like).

Examining the results of "phrase" based searches using Advanced has the same exact query as simply 'any'. Also Joomla searches have the same exact queries of the use of LIKE '%value%'. Simple 'any' should give you the results you need, but am suspecting tampering (core edits) or a conflict of sorts (CB plugin or Joomla system plugin).

Post edited by: krileon, at: 2010/04/22 19:48


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

13 years 11 months ago #133201 by carsten888
Replied by carsten888 on topic Re:Why wont my CB search produce proper results?
same issue here.
Got number of clients who have 'discovered' this search behaviour. One client wants me to build an 'exact search option'. A checkbox next to the search-field, so when ticked will search exact. Can anyone direct me to where the search-query can be found?

If I manage, I will post the fix here.

Please Log in to join the conversation.

13 years 11 months ago #133268 by krileon

Got number of clients who have 'discovered' this search behaviour. One client wants me to build an 'exact search option'. A checkbox next to the search-field, so when ticked will search exact. Can anyone direct me to where the search-query can be found?

Setting your userlist to use advanced searching will provide your clients with what they are requesting. We do not support core edits and can not advise on that matter, sorry.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

13 years 11 months ago #133344 by carsten888
Replied by carsten888 on topic Re:Why wont my CB search produce proper results?
thank you :pinch:

I got it!

version: 1.2.1 (so I don't know about how this works out in the latest version, someone confirm please)
file: administrator/components/com_comprofiler/plugin.class.php
line: 2354
[code:1]return $condition;[/code:1]
change to
[code:1]//dirty hack to make search for exact name possible
if(strpos($condition, 'u.`username') && strpos($condition, 'OR')){
//there is a search for username and there are more then one
if(JRequest::getVar('exact_name_search', '')){
//exact name search is desired
//get the name field as posted
$search_username = JRequest::getVar('username', '');
$search_username = strip_tags($search_username);
$condition = "(u.`username` LIKE '%".$search_username."%')";
}
}

return $condition;[/code:1]

then to add a checkbox next to the name-search-field I used JQuery because CB templating is ... well ... tricky to say the least.

So in my template file I load the javascript when on the CB userlist page like this:
[code:1]<?php if($option=='com_comprofiler' && JRequest::getVar('task', '')=='usersList'){
echo '<script type="text/javascript" src="templates/templatename/javascript/add_exact_search_checkbox.js"></script>';
}
?>
[/code:1]

this is the JQuery code to add the checkbox next to the searchfield:

[code:1]var exact_name_search_jQuery = jQuery.noConflict();
exact_name_search_jQuery(document).ready(function() {

//add checkbox
exact_name_search = ' <input type="checkbox" name="exact_name_search" value="1" /> make exact search on name';
exact_name_search_jQuery("#username"«»).after(exact_name_search);

});[/code:1]
make sure JQuery is already loaded when using this.

Post edited by: carsten888, at: 2010/05/18 15:46

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.283 seconds

Facebook Twitter LinkedIn