Join our new community forum for support & discussion

Join Now

Home Support Themes ListingHive Customize Search Form

Customize Search Form

  • Author
    Posts
  • sebastian

    I wish to delete the second search field in listing hive theme which actually is filled with geolocation placeholder. Where can I change/override the sourcecode?

    Kind regards.
    Sebastian

    yevhen developer

    Please try this PHP snippet

    // Delete field from search bar.
    add_filter(
    	'hivepress/v1/forms/listing_search',
    	function( $form ) {
    		if ( isset( $form['fields']['location'] ) ) {
    			unset($form['fields']['location']);
    		}
    
    		return $form;
    	},
    	1000
    );
    sebastian

    Where to insert this PHP snippet?

    At > theme data editor?

    yevhen developer

    Please try Code Snippets plugin to put snippets on your website https://wordpress.org/plugins/code-snippets/

    sebastian

    Now it works! Thanks!!

Viewing 5 posts - 1 through 5 (of 5 total)

New Reply

This forum has been archived and is no longer accepting new posts or replies. Please join our new community forum for support & discussion.