File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes PHP and the fly likes PHP Ajax Livesearch Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Languages » PHP
Bookmark "PHP Ajax Livesearch" Watch "PHP Ajax Livesearch" New topic

PHP Ajax Livesearch

Mahtab Alam
Ranch Hand

Joined: Mar 28, 2012
Posts: 388

I`m looking to implement the google`s autosuggest with php and ajax.I searched a lot on the web , but can`t find the solution i`m looking for.
I want that data to be looked is from the database not from the xml file.

Oracle Java Programmer , Oracle SQL Expert , Oracle Java Web Component Developer, Oracle Web Service Developer
timo corn
Ranch Hand

Joined: Oct 26, 2013
Posts: 68

You must need a key-... event to get input values, Info here

Quote from another site:
keydown and keyup talk about which key has been changed. keypress tells which character that key represents

Then you need ajax, beforehand you get the input value (keys) from the form input field with $(this).val():

As an ocjp an easy task.

Mahtab Alam
Ranch Hand

Joined: Mar 28, 2012
Posts: 388

Thank you timo for answering my questions .
Thanks again
Supun Lakshan Dissanayake
Ranch Hand

Joined: Oct 26, 2012
Posts: 135

What did you meant by LiveSearch

Dis you mean This

Are you better than me? Then please show me my mistakes..
I agree. Here's the link:
subject: PHP Ajax Livesearch
It's not a secret anymore!