XSL 変換に基づいて XML 結果を表示するために使用しているテーブルをドレスアップするためにDataTablesを使用しています。技術的な意味 (ページング、並べ替え、フィルタリング) ですべてが機能していますが、ThemeRoller テーマを使用して、Web サイトにあるように見えるようにしようとしています。
これまでのところ、次のファイルを参照とともにプロジェクトに追加しました。
<link type="text/css" href="css/custom-theme/jquery-ui-1.8.7.custom.css" rel="stylesheet"/>
DataTables Web サイトに従って、次を使用して ThemeRoller テーマを有効にしました。
$(document).ready(function() {
$('#mainTable').dataTable( {
"bJQueryUI": true,
"sPaginationType": "two_button"
});
});
テーブルのスタイルが設定されますが、ヘッダー行が広すぎて、1 行にあるはずのものが複数行にあるため、正しく表示されません。私が間違っていることについての兆候はありますか?よろしくお願いします。
HTML コード:
<html>
<body>
<head runat="server">
<META http-equiv="Content-Type" content="text/html; charset=utf-8">
<link type="text/css" href="css/custom-theme/jquery-ui-1.8.7.custom.css" rel="stylesheet">
<script src="Scripts/jquery-1.4.4.min.js" type="text/javascript">
</script>
<script src="Scripts/jquery.dataTables.min.js" type="text/javascript">
</script>
<script type="text/javascript">
$(document).ready(function() {
$('#example').dataTable( {
"bJQueryUI": true
});
});
</script>
</head>
<table cellpadding="0" cellspacing="0" border="0" id="example" class="display">
<thead>
<tr>
<th>
<h3>Title</h3>
</th>
<th>
<h3>URL</h3>
</th>
<th>
<h3>Notes</h3>
</th>
<th>
<h3>
</h3>
</th>
</tr>
</thead>
<tbody>
<tr>
<td>
<a href="http://www.roperband.com">Jesse\'s Article</a>
</td>
<td>
<a href="http://www.roperband.com">http://www.roperband.com</a>
</td>
<td>Some of Jesse\'s notes</td>
<td>
</td>
</tr>
</tbody>
</table>
</body>
</html></span>
</div>
<div class="clear">
</div>
<div class="footer">
</div>
</form>
</body>
</html>