-
If I will insert ads search block in ads home then I will have total 3 block on page. i have listed block in order it will be on page.
1- Search Form Block - This is fine
2 - latest Ads Block - This will be display latest ads as soon as user will land on ads ome page.
3- Ads search Block - This block will be empty on first time user will come to Ads home page.
So once user click on search form then I want latest ads block to be hieden and so result in ads search block.
-
It will require to have the custom JS / JQuery code which will hide this block before the submit of the search form.
-
I thought so and issue is that how Js will know if button is pressed ? i was not able to figure it out .. I was thinking that Page will refreshed and i can use any anchor to trigger Java Script and hide latest ads block. Any thoughts?
-
Yes, JQuery may "listen" the actions of the forms like:
$( "#search_form_id" ).on( "submit", function( event ) { alert( "Handler for `submit` called." ); event.preventDefault(); });
-