私はすべてを試しましたが、それでも失敗します!このコードの何が問題になっていますか?!?!シリアル化されたソート可能ファイルを取得したかったのですが、それはとても単純ですが、SOを調べて、コードに適用されたスニペットを見つけましたが、それでも機能しません。それはまったく意味がありません。考えられるエラーを調べました(もちろん、jQuery docで指定されているset_numberがあります)...それでも何も機能しません。
<html>
<body>
<script type='text/javascript' src='http://code.jquery.com/jquery-1.5.js'>
</script>
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.9/jquery-ui.js">
</script>
<script>
$(function() {
$( "#sortable" ).sortable();
$( "#sortable" ).disableSelection();
});
$("form").submit(function(){
$('#thedata').val($( "#sortable" ).sortable("serialize"));
return false;
});
</script>
<h1>
Filters For Tables
</h1>
<h2>
Filters for Assets
</h2>
<form action="validate.php" method="post">
<input type='text' name='thedata' id='thedata' />
<ul id="sortable">
<li id="foo_0">ID</li>
<li id="foo_1">TIME LOG</li>
<li id="foo_2">DEVICE TYPE</li>
<li id="foo_3">CHASSIS TYPE</li>
<li id="foo_4">PARENT ID</li>
<li id="foo_5">PARENT</li>
</ul>
<input type="submit" name="submit" id="submit" value="Update" />
</form>
</body>
</html>