Hello,
is it a way in CSS to display the search tooltip field on page load.
I need this search field to be more visible for my site users.
Thanks
Hey coolpaie,
Could you please attach a mockup of what you’re trying to achieve?
Best regards,
Victoria
Hello,
i just need to display the search box at page load instead of having to click on the magnifying glass button
Hi,
Try adding this code to the end of your functions.php file in Appearance > Editor:
function open_search(){
?>
<script>
(function($){
$(window).load(function() {
$('.menu-item-search-dropdown a').trigger('click');
});
})(jQuery);
</script>
<?php
}
add_action('wp_footer', 'open_search');
Best regards,
Mike
Thanks a lot, it’s working like a charm.
Cordialement
michel