0
複数の選択ボックスに1つの問題があります。私は複数の選択ボックスを書いているコンテナ内に固定サイズのコンテナを持っています。複数選択:長いオプションを選択する際の問題
オプション値には説明的な長いデータがあります。だから、overflow-x : auto
にデータを選択して横にスクロールして内容を読む必要があります。
データを選択して横方向にスクロールしようとすると、コンテンツ全体を読むと表示されるはずの他の部分は表示されません(スクロールする必要があるため表示されません)。
このサンプルコードを貼り付け、任意のデータを選択して水平方向にスクロールして、情報が部分的に選択されていることを確認してください。ここ
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>My Application</title>
<style type="text/css">
.test{
width:300px;
}
select{
width: 100%;
overflow-x: scroll;
}
</style>
<script type="text/javascript" src="http://code.jquery.com/jquery.min.js" charset="utf-8"></script>
</head>
<body>
<div class="test">
<select name="myMultipleTest" id="myMultipleTest" multiple="multiple">
<option value="A101">This is a sample long text which contains some information</option>
<option value="A102">This is a sample long text which contains some information, which might contain some information which is long in description</option></select>
</div></body>
</html>