bootstrap使用

1.点击一个图标,在点击的地方弹出一个层提示信息

<span class="fa fa-exclamation-circle fa-lg" style="color:red" title="错误提示信息" data-container="body" data-toggle="popover" data-placement="bottom" data-content="@ViewBag.InstallmentPartherExtend.Remark"></span>

 

2、IE 兼容模式

Bootstrap 不支持 IE 古老的兼容模式。为了让 IE 浏览器运行最新的渲染模式下,建议将此 <meta> 标签加入到你的页面中:

<meta http-equiv="X-UA-Compatible" content="IE=edge">
按 F12 键打开 IE 的调试工具,就可以看到 IE 当前的渲染模式是什么。

 

3、Bootstrap支持可输入下拉框

https://files.cnblogs.com/files/slyzly/jquery.editable-select.zip

@section styles
{
<link href="~/Content/css/jquery.editable-select.min.css" rel="stylesheet" />
}

@Html.DropDownListFor(m => m.SoftType, ViewBag.SoftType as List<SelectListItem>, new { @class = "form-control" })

<script type="text/javascript" src="~/Scripts/jquery.editable-select.min.js"></script>

$('#document').ready(function () {

    $('#SoftType').editableSelect({
        effects: 'slide',
        //可选参数default、fade
        filter: false // 不过滤,否则选中后其它选项消失
    });

    $("#SoftType").val("@Model.SoftType");//设置默认值

});

 

posted @ 2017-10-23 08:36  事理  阅读(113)  评论(0编辑  收藏  举报