jquery autocomplate源文件错误

时间:2015-12-22 20:33:31

标签: php jquery

什么?我做源PHP文件。当我测试时打开所有列表打开。但不行。我写的例子

<!doctype html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <title>autocomplete demo</title>
  <link rel="stylesheet" href="//code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css">
  <script src="//code.jquery.com/jquery-1.10.2.js"></script>
  <script src="//code.jquery.com/ui/1.11.4/jquery-ui.js"></script>
</head>
<body>

<label for="autocomplete">Select a programming language: </label>
<input id="autocomplete">

<script>
$( "#autocomplete" ).autocomplete({
  source: "text.php"

});
</script>

</body>
</html>

这个test.php

[ "Apple",
"Banana",
"Mango",
"Lemon",
"Öküz helvası"
]

0 个答案:

没有答案