"YOU AND THE ART OF ONLINE DATING" is the only product on the market that will take you step-by-step through the process of online dating, provide you with the resources to help ensure success. Get it now!
Up vote 0 down vote favorite 1 share g+ share fb share tw.
I added codes (jQuery) for keyPress and click of search textbox and button respectively. Now the search query reflects in the browser (http://samplesite/default. Aspx?
K=query) when I click the button, but it does not when I press enter inside the search textbox. Anyone know this issue? Thanks.
// Keypress event for search box $('#search-box'). Keypress(function (e) { if ((e. Which && e.
Which === 13) || (e. KeyCode && e. KeyCode === 13)) { Search(); }; }); // Click event for search button $('#search-button').
Bind('click', function () { Search(); }); p.s. Im using location. Assign jquery keypress link|improve this question edited Aug 12 '10 at 8:46Reigel18.2k12041 asked Aug 12 '10 at 7:21SajmiraZ93 80% accept rate.
– James Wiseman Aug 12 '10 at 7:39 here it is. // Keypress event for search box $('#search-box'). Keypress(function (e) { if ((e.
Which && e. Which === 13) || (e. KeyCode && e.
KeyCode === 13)) { Search(); }; }); // Click event for search button $('#search-button'). Bind('click', function () { Search(); }); – SajmiraZ Aug 12 '10 at 7:47.
You can try this: $('#search-button'). Bind('click', function () { Search(); }); // order is important! $('#search-box').
Bind(($.browser. Opera? "keypress" : "keydown"), function (e) { // opera handle keypress differently if (e.
KeyCode && e. KeyCode === 13) { $('#search-button').click(); }; }); Also, you can try jquery. Hotkey too.
Thanks. I will try this and will let you know. ^_^ – SajmiraZ Aug 12 '10 at 8:58 k parameter is still not updating, I am using IE 7.
Is there an issue with location. Assign? Or its just that keyPress won't update the url in the browser textbox in IE 7 and only when you click a button?
Thanks again. – SajmiraZ Aug 12 '10 at 9:40 I never used location.assign. But you can try to use window.location.
Assign instead. Try to debug with console.log() or just alert() to see where the whole thing is stuck. – Ionut Staicu Aug 12 '10 at 9:52 I will try your suggestion.
I tried debugging this and found out that the variable that holds the URL is the same on both click and keypress (before passing it to location. Assign) but its just that keypress won't update the url in the browser. Thanks again.
– SajmiraZ Aug 12 '10 at 9:54 But you know you can use $('form').submit(), right? (or you use that dumb thing called web forms? ) – Ionut Staicu Aug 12 '10 at 10:19.
I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.