再会!基本上,我希望在单击复选框时出现一个文本框,并在未单击时消失。这是 JSFiddle http://jsfiddle.net/GBSZ8/2/,它工作得很好。但是,当我将其保存为 check.php 时,即使单击复选框也不会出现文本框。
<html>
<head>
<script>
$('#supplied').live('change', function(){
if ( $(this).is(':checked') ) {
$('#date').show();
} else {
$('#date').hide();
}
});
</script>
</head>
<body>
<input type="checkbox" name="supplied" id="supplied" value="supplied" class="aboveage2" />
<ul id="date" style="display:none">
<li><input id="start" name="start" size="5" type="text" class="small" value="1" /></li>
</ul>
</body>
</html>
请帮我。谢谢!