Leo
(@leohsiang)
Hi there,
We actually have a site library template with a header very similar to that which might be worth considering:
https://gpsites.co/prime/
If not, are you just using the default search widget from WordPress?
Hi Leo,
Thanks for reply. Indeed it is nice one.
Should we buy pro version to get this design?
And yes, default search engine will be used. What is your suggestion? 🙂
Thank you
Leo
(@leohsiang)
Getting GP Premium would be the easiest solution as you can just import the layout.
If not we can also make it work with the free version.
Can you link me to your site in question? Are you just using the default search widget from WordPress?
Hi @leohsiang ,
I will build the site from zero.
If you can teach me i can start with it.
Many thanks for great support.
Leo
(@leohsiang)
Will you be using the default search widget then?
Prime is using this plugin:
https://en-ca.wordpress.org/plugins/ajax-search-for-woocommerce/
I can use yours, Ajax is additional feature.
Thank you
Leo
(@leohsiang)
Once you’ve added the plugin, add this PHP snippet:
add_action( 'generate_after_header_content', function() {
?>
<div class="woo-search">[wcas-search-form]</div>
<?php
} );
Adding PHP: https://docs.generatepress.com/article/adding-php/
You might need to make sure the shortcode matches.
Link me to the site after that’s done.
that is done, site address will be this.
Leo
(@leohsiang)
That link requires a login and password.
Can you provide the viewable access?
Leo
(@leohsiang)
I’m just seeing the shortcode.
Have you installed and activated the Ajax plugin?
Actually yes, it is activated
Leo
(@leohsiang)
Hmm can you try this?
add_action( 'generate_after_header_content', function() {
?>
<div class="woo-search"><?php echo do_shortcode('wcas-search-form'); ?></div>
<?php
} );
I have delete everything and installed again. now i can see search bar.
Leo
(@leohsiang)
Now it’s added as a header widget instead of a hook.
But you can try this CSS to make it bigger:
.header-widget {
width: 75%;
max-width: unset;
}
Adding CSS: https://docs.generatepress.com/article/adding-css/