Use json_encode to encode values for the autocomplete boxes.

Let var_export handle the encoding.