Page 1 of 1

Searchbar control

Posted: Tue Sep 10, 2013 11:54 pm
by Roger

how can I determine when the clear button of a search bar is clicked


Searchbar control

Posted: Wed Sep 11, 2013 12:26 am
by Igor

Hello,

Please try to add next code to page load event
pre
$(document).on('click', '.ui-input-clear', function () {
alert('cleared');
});
/pre


Searchbar control

Posted: Wed Sep 11, 2013 12:50 am
by Roger

Works great....Thanks


Searchbar control

Posted: Tue May 20, 2014 8:43 pm
by Roger

This appears to trap the entire app. Is there a way to do this by page?


Searchbar control

Posted: Wed May 21, 2014 1:43 pm
by Evgene Karachevtsev

Hello Roger,

Please try this code:

code$("[dsid='startScreen']").on('click', '.ui-input-clear', function () {
alert('cleared');
});
//where startScreen - name of page /code


Searchbar control

Posted: Wed May 21, 2014 1:47 pm
by Roger

This seems to work just fine.

$(document).on('click', '#PriceMaint .ui-input-clear', function () {

});


Searchbar control

Posted: Wed May 21, 2014 2:10 pm
by Evgene Karachevtsev

Roger,

Thank you for the update. Let us know if you need any further help.


Searchbar control

Posted: Wed May 21, 2014 2:10 pm
by Roger

Great, THANK YOU!!


Searchbar control

Posted: Wed May 21, 2014 6:39 pm
by Roger

The following works by page. But now within a page it will grab and control with .ui-input-clear. I would like to limit the code below for searchbar controls. Is that possible?

$(document).on('click', '#PriceMaint .ui-input-clear', function () {


Searchbar control

Posted: Thu May 22, 2014 8:24 am
by Evgene Karachevtsev

Hello Roger,

Could you please try this one:

code$(document).on('click', 'div.startScreen_mobilesearchbar_2 .ui-input-clear', function () {
alert('cleared');
}); /code

//where startScreen - name of pageg
mobilesearchbar_2 - name of searchbar