Archived topic
Search button text missing
20 replies · Started by Dan on September 21, 2021
Any idea why the text is missing on the search button?
I also tried this, but didn't help:
add_filter( 'generate_search_button', function() {
return 'Search me';
} );
Screenshot:
https://www.dropbox.com/s/fq1185tjji6ef0p/search-button-missing.jpg?dl=0
Thanks
Dan
Hi there,
Any chance you can link us to the site in question?
You can use the private information field:
https://docs.generatepress.com/article/using-the-premium-support-forum/#private-information
Let me know :)
sorry it's still on localhost
How's that search form added?
I tried both via a shortcode (relevansii plugin) and a template tag get_search_form();
They are added to the page via a hook.
I tried to disable the plugin too, but result is the same
Can you try using a search block from WP core? Then you should be able to change the button text or add placeholder without using a snippet.
I can add the search block, and it displays correctly, but then I can't limit to search only in a CPT.
Adding a template tag or a shortcode does not allow to add text to the button or modify the placeholder text.
Really strange...
but then I can’t limit to search only in a CPT.
How are you doing that right now anyways?
The get_search_form(); uses the same thing as the search block. They are both WordPress options.
Hi Leo
I have uploaded the site to a staging environment, I have added the site's url in the private section.
I also created a user for you.
Let me know if you need more info.
Thanks
Dan
Hi there,
is there a specific page where we can see the search form ? Sorry if its somewhere obvious ... :)
sure, added the links in the private info window.
Hmm not really sure what's causing this.
Can we try a CSS solution?
.search-form button.search-submit:before {
content: "Search Me";
}
Thanks Leo, but I will need to find the underlying issue
Can you try using SVG?
https://docs.generatepress.com/article/svg-icons/