Top Menu

The following PHP and jQuery snippet allows you to type the search phrase and display what you have typed in the results field. I am showing you this technique to use jQuery to know what you are typing in the search field. Usually, you would use Ajax to display the results from the database. I didn’t here and I just want to show you the keystrokes and character changes that you can capture on the fly as the user is typing. You can use this code as a stepping stone to display your results quickly without refreshing the page nor waiting for the user to finish typing.

See it in action here.


About The Author

I write about my life!