为了账号安全,请及时绑定邮箱和手机立即绑定

急急急急急急! 在线等

急急急急急急! 在线等

你造吗_ 2016-02-25 21:28:42
<div class="select"> <div class="ul-1 dis-in"> <div class="form_group"> <label class="form_label ml15 text-l"><i class="red">*</i>Product Line</label> </div> <ul class="bor-top"> <li>Carrier Software</li> <li class="bg-back"><span class="c-elongation">Common Field</span></li> <li>Core Network</li> <li class="bg-back"><span class="c-elongation">Device IC</span></li> <li>Device Cloud</li> <li class="bg-back"><span class="c-elongation">Enterprise Business Service</span></li> <li>Enterprise Vertical Industries Solutions</li> <li class="bg-back"><span class="c-elongation">Carrier Software</span></li> <li>Common Field</li> <li class="bg-back"><span class="c-elongation">Core Network</span></li> <li>Device IC</li> <li class="bg-back"><span class="c-elongation">Device Cloud</span></li> <li>Device IC</li> <li class="bg-back"><span class="c-elongation">Device Cloud</span></li> </ul> </div> <div class="ul-2 dis-in"> <div class="form_group"> <label class="form_label ml15 text-l"><i class="red">*</i>Product Family</label> </div> <ul class="bor-top"> <li>Carrier Software</li> <li class="bg-back"><span class="c-elongation">Common Field</span></li> <li>Core Network</li> <li class="bg-back"><span class="c-elongation">Device IC</span></li> <li>Device Cloud</li> <li class="bg-back"><span class="c-elongation">Enterprise Business Service</span></li> <li>Enterprise Vertical Industries Solutions</li> <li class="bg-back"><span class="c-elongation">Carrier Software</span></li> <li>Common Field</li> <li class="bg-back"><span class="c-elongation">Core Network</span></li> <li>Device IC</li> <li class="bg-back"><span class="c-elongation">Device Cloud</span></li> <li>Device IC</li> <li class="bg-back"><span class="c-elongation">Device Cloud</span></li> </ul> </div> <div class="ul-3 dis-in"> <div class="form_group"> <label class="form_label ml15 text-l"><i class="red">*</i>ProducttPDT</label> </div> <ul class="bor-top"> <li>Carrier Software</li> <li class="bg-back"><span class="c-elongation">Common Field</span></li> <li>Core Network</li> <li class="bg-back"><span class="c-elongation">Device IC</span></li> <li>Device Cloud</li> <li class="bg-back"><span class="c-elongation">Enterprise Business Service</span></li> <li>Enterprise Vertical Industries Solutions</li> <li class="bg-back"><span class="c-elongation">Carrier Software</span></li> <li>Common Field</li> <li class="bg-back"><span class="c-elongation">Core Network</span></li> <li>Device IC</li> <li class="bg-back"><span class="c-elongation">Device Cloud</span></li> <li>Device IC</li> <li class="bg-back"><span class="c-elongation">Device Cloud</span></li> </ul> </div> <div class="ul-4 dis-in"> <div class="form_group"> <label class="form_label ml15 text-l"><i class="red">*</i>Product</label> </div> <ul class="bor-top"> <li>Carrier Software</li> <li class="bg-back"><span class="c-elongation">Common FieldCommon FieldCommon FieldCommon FieldCommon FieldCommon FieldCommon FieldCommon Field</span></li> <li>Core Network</li> <li class="bg-back"><span class="c-elongation">Device IC</span></li> <li>Device Cloud</li> <li class="bg-back"><span class="c-elongation">Enterprise Business ServiceEnterprise Business ServiceEnterprise Business ServiceEnterprise Business Service</span></li> <li>Enterprise Vertical Industries Solutions</li> <li class="bg-back"><span class="c-elongation">Carrier Software</span></li> <li>Common Field</li> <li class="bg-back"><span class="c-elongation">Core Network</span></li> <li>Device IC</li> <li class="bg-back"><span class="c-elongation">Device Cloud</span></li> <li>Device IC</li> <li class="bg-back"><span class="c-elongation">Device Cloud</span></li> </ul> </div> <div class="windFooter ta-c mt10">            <span class="btnBlue mr20">ok</span><span class="btnWhite close">Close</span>        </div></div>css:.windBlockP{width: 1260px;}.dis-in{width: 280px;display: inline-block;margin-left: 20px;}.dis-in .bor-top{border-top: 1px solid #ddd;overflow: scroll;height:397px;}.form_group .text-l{text-align: left;color: #323232;}.dis-in li{height: 32px;line-height: 32px;text-indent: 10px;white-space:nowrap;width: auto;color: #888;}.dis-in li:hover{background-color:#c9ebff; color:#333333;}.dis-in .bg-back{background-color: #eff9ff;}.c-elongation{display: inline-block;background-color: #eff9ff;text-indent: 0;}.dis-in li:hover .c-elongation{background-color:#c9ebff; color:#333333;}谁会写jquery啊,解决上面的问题。li是用户输入的内容,超出会出现滚动条。获取最大一个宽度的li,在让所有的li和它等宽。
查看完整描述

1 回答

已采纳
?
慕郎_莲华

TA贡献83条经验 获得超16个赞

记得选择代码语言~好看些//img1.sycdn.imooc.com//56d033b60001492d01760300.jpg

var max = 0;

$('li').each(function(){
    var w = $(this).width();
    
    if(w > max){
        max = w;
    }
});

$('li').css('width', max)


查看完整回答
反对 回复 2016-02-26
  • 1 回答
  • 0 关注
  • 1553 浏览
慕课专栏
更多

添加回答

举报

0/150
提交
取消
意见反馈 帮助中心 APP下载
官方微信