The issest way is to hide the search conditionally via CSS. Here is PHP snippet you can apply.
add_action( 'wp_head', function () {
$r = $_SERVER['REQUEST_URI'];
if ( ! empty( $r ) && strpos( $r, '/negozio/' ) !== false ) {
?>
<style>
.dgwt-wcas-widget {
display: none;
}
</style>
<?php
}
} );
You have two ways to add this code to your theme:
Open the functions.php in your Child Theme and add the code at the end
or install the Code Snippets plugin and apply this code as a snippet
Best
Damian
works perfectly, thanks.
Because the site has a second language, I’m sure I can duplicate the snippet changing the name of the page, but there is a way to include both pages in the same code so to avoid having two snippets doing the same??
that’s the ENG url
https://www.mercatodeivignaioli.it/en/shop/
Ok, I wrote a code. Thanks
Then use it:
add_action( 'wp_head', function () {
$r = $_SERVER['REQUEST_URI'];
if ( ! empty( $r ) &&
( strpos( $r, '/negozio/' ) !== false || strpos( $r, '/en/shop/' ) !== false )
) {
?>
<style>
.dgwt-wcas-widget {
display: none;
}
</style>
<?php
}
} );