如何從傳統asp頁面獲取JQuery自動完成UI的源代碼?jQuery自動完成UI從asp頁面獲取源碼
我發現了默認代碼。但我想從另一個asp頁面中獲取結果。我怎樣才能發送與asp和獲得jQuery?
我需要一點幫助。
<html lang="en">
<head>
<meta charset="utf-8" />
<title>jQuery UI Autocomplete - Default functionality</title>
<link rel="stylesheet" href="http://code.jquery.com/ui/1.10.0/themes/base/jquery-ui.css" />
<script src="http://code.jquery.com/jquery-1.8.3.js"></script>
<script src="http://code.jquery.com/ui/1.10.0/jquery-ui.js"></script>
<link rel="stylesheet" href="/resources/demos/style.css" />
<script>
$(function() {
var availableTags = [
"ActionScript",
"AppleScript",
"Asp",
"BASIC",
"C",
"C++",
"Clojure",
"COBOL",
"ColdFusion",
"Erlang",
"Fortran",
"Groovy",
"Haskell",
"Java",
"JavaScript",
"Lisp",
"Perl",
"PHP",
"Python",
"Ruby",
"Scala",
"Scheme"
];
$("#tags").autocomplete({
source: availableTags
});
});
</script>
</head>
<body>
<div class="ui-widget">
<label for="tags">Tags: </label>
<input id="tags" />
</div>
</body>
</html>
感謝您的回答,我認爲第一個解決方案可能對我有用。 「<%= getListOfTags()%>」函數返回什麼樣的列表,你可以舉例?再次感謝 –
我會在一個小時左右的電腦,我會張貼一些東西... – Mortalus
謝謝,即時通訊仍然與它奮鬥 –