andrea

Forum Replies Created

Viewing 14 posts - 1 through 14 (of 553 total)
  • Author
    Posts
  • in reply to: displaying autocomplete #11218
    andrea
    Keymaster

    Hi Clara,

    If you don’t have a bp-custom.php file, you can create it under wp-content/plugins.

    See https://codex.buddypress.org/themes/bp-custom-php/

    in reply to: displaying autocomplete #11213
    andrea
    Keymaster

    Hello Clara,

    As promised, I wrote a post explaining how to register a Custom Taxonomy Multiselector field, and another post explaining how to add Select2 to your search forms, without having to write a new form template.

    If you apply both, you could achieve the purpose you detailed in your original post.

    https://dontdream.it/taxonomy-search/
    https://dontdream.it/enabling-select2/

    Please let me know if something doesn’t work for you as expected!

    in reply to: Перепутаны значения #11204
    andrea
    Keymaster

    Hi Валерий,

    I’ve just published a post on the problem you are reporting:

    https://dontdream.it/swap-the-labels/

    I hope you find the solution useful!

    in reply to: Placeholder text is missing #11164
    andrea
    Keymaster

    Hi Gautham,

    To add a placeholder to a drop-down field, place this code in your bp-custom.php or functions.php file:

    add_action ('bps_field_before_search_form', 'set_placeholder');
    function set_placeholder ($f)
    {
    	if ($f->code == 'field_35' && $f->display == 'selectbox')
    	{
    		$f->options[''] = 'select a value...';
    	}
    }

    Replace 35 with the actual field ID of your profile field.

    If you wish to force a default value instead, please have a look at:

    https://dontdream.it/bp-profile-search-5-3/

    in reply to: displaying autocomplete #11155
    andrea
    Keymaster

    Hello Clara,

    BuddyPress Xprofile Custom Field Types supports integration with BP Profile Search, but not for all of their custom field types. The Custom Taxonomy Selector is one of the unsupported types.

    I’ve received many request on this topic, so I’m going to write a tutorial on the integration of taxonomy field types.

    But even when the integration is in place, the autocomplete won’t work in a search form. You’ll need to write a custom form template that ‘copies’ the autocomplete logic from BuddyPress Xprofile Custom Field Types.

    Please let me know if you have more questions!

    in reply to: If>So #11152
    andrea
    Keymaster

    Hello gg,

    Unfortunately that feature is not available, but you or your developer could implement it with JavaScript in a custom form template.

    After you configure a standard form to contain all the relevant fields, add to the form template some JavaScript code to selectively hide or show the ‘secondary’ fields, depending on the value of the ‘primary’ field.

    in reply to: Change searchform location #11146
    andrea
    Keymaster

    Hi Timothy,

    You could use the Profile Search widget to add a search form in a sidebar or widget area, or the [bps_form] shortcode to add a form in a post or page.

    If you wish to add a form in a different place, you have to add a line of code in the relevant template:

    echo do_shortcode( '[bps_form id=1234]' );

    Replace 1234 with the actual ID of your form.

    in reply to: CSS Menu Builder #11118
    andrea
    Keymaster

    Hi Geraldo,

    That’s too bad!

    Unfortunately I don’t know how to contact the site author, so let’s hope it’s just a temporary problem.

    in reply to: Change text search to dropdown select #11097
    andrea
    Keymaster

    Hi Malik,

    Yes, the downside is that you have to manually update the drop-down profile field.

    If the options are too many or change frequently that’s not easy, but with the current plugin version I can’t think of a better solution. Sorry!

    in reply to: Change text search to dropdown select #11084
    andrea
    Keymaster

    Hi Malik,

    Unfortunately that’s not possible, unless you change the BuddyPress profile field type to drop-down. But probably this is not what you want?

    in reply to: Members swap page not display correctly #11077
    andrea
    Keymaster

    Hi Kenneth,

    I’ve removed your login credentials, because this forum is public. I urge you to change those credentials immediately.

    About your question, that page is part of your theme, Gwangi, and the template is not provided by BP Profile Search. I suggest you ask the Gwangi team for advice.

    in reply to: Directory Of Users With Certain Field Input #11073
    andrea
    Keymaster

    Hi Jake,

    Probably you could use the ‘hidden filters’ feature, see:

    https://dontdream.it/bp-profile-search-4-8/

    Is that what you need?

    andrea
    Keymaster

    You are welcome!

    andrea
    Keymaster

    Hi James,

    Leading and trailing spaces are included in the search string by design but, if you wish to remove them, you can add this code to your bp-custom.php file:

    add_filter ('bps_request', 'trim_values', 10, 3);
    function trim_values ($request, $type, $form)
    {
    	$key= 'field_45_contains';
    	if (isset ($request[$key]))
    		$request[$key] = trim ($request[$key]);
    	return $request;
    }

    Replace 45 with the actual ID of the field you want to trim.

Viewing 14 posts - 1 through 14 (of 553 total)