1 <select id="single">2 <option>选择1号</option>3 <option>选择2号</option>4 <option value="选择2号">选择3号</option>5 </select>6 7 $("input:eq(0)").click(function(){8 $("#single").val("选择2号");9 });在jquery中,val()方法是 Read More
posted @ 2012-09-20 16:39 vincent_ds Views(351) Comments(0) Diggs(0)
后代选择器和过滤选择器不同 1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> 2 <html xmlns="http://www.w3.org/1999/xhtml"> 3 <head> 4 <title> new document </title> 5 <meta http Read More
posted @ 2012-09-20 11:08 vincent_ds Views(524) Comments(0) Diggs(0)