javascript - JQuery UI Autocomplete with PHP file source -


With the data coming from a remote source (another php script), trying to use JQueryUI autocomplete I am here. Below is an example given in the demo on the jQueryUI website:

    

My question is about PHP script "search.php" Can this script only return an array?

Feedback in one of these two JSON formats Array Format:

An array of strings:

["Choice 1", "Choice 2"]

OR

[[label: "choice1", value: "value1"}, ...] code>

Comments