小编S.S*_*han的帖子

按下后如何删除<select>上的边框突出显示

<select>聚焦后如何禁用边框突出显示(轮廓)。我可以禁用它像其他元素<input><textarea><button>而不是<select>标签。

这是我的CSS,我确实包含了select:focus它,但是它不起作用。:(

input:focus,
select:focus,
option:focus,
textarea:focus,
button:focus {
    outline: none;
}
Run Code Online (Sandbox Code Playgroud)

这是代码段:

input:focus,
select:focus,
option:focus,
textarea:focus,
button:focus {
    outline: none;
}
Run Code Online (Sandbox Code Playgroud)
input:focus,
select:focus,
textarea:focus,
button:focus {
  outline: none !important;
}

body {
  padding: 40px 20px 20px 20px;
}

.qa-collapse {
  background-color: rgb(245, 245, 245);
}

.qa-input {
  border-top-left-radius: 50px;
  border-bottom-left-radius: 50px;
  border-right: none !important;
  border: 1px solid #F2F2F2;
  width: 82%;
  padding: .25rem .75rem;
  font-size: 1rem;
  line-height: 1.5;
  color: #495057; …
Run Code Online (Sandbox Code Playgroud)

html css bootstrap-4

5
推荐指数
1
解决办法
1548
查看次数

在 IIS 中托管 asp.net 核心应用程序以从网络内的其他 PC 访问

我如何在 Windows IIS 中托管我的 Asp.Net Core(1、2 或 2.1)Web 应用程序,以便能够从我们本地网络(或我的虚拟操作系统)中的其他 PC 访问它?我的 PC 是台式机 Windows 10 Pro(不是 Win Server)。

我已经使用 IIS文章关注了 Windows 上Host ASP.NET Core,但我无法让它工作。

我根据那篇文章所做的如下:

确保Prequisites:Visual Studio的2017年,安装Asp.Net 2.1核心SDK,从添加Internet信息服务(IIS)Turn Windows features on or off,Asp.Net核心主机捆绑安装程序从这里(验证在IIS AspNetCoreModule模块),然后:

将 Visual Studio 中的默认 asp.net 核心应用程序(构建 > 发布 > 文件夹)发布到文件夹并将其内容复制到D:\publish1.

在 IIS 中,右键单击站点 > 添加网站...并使用这些值(根据此处显示的图片):

  [Site name]: mysite_com
  [Physical path]: `D:\publish1`
  [IP address]: `All Unassigned`
  [Port]: 80
  [Host name]: mysite.com …
Run Code Online (Sandbox Code Playgroud)

deployment iis host asp.net-core

4
推荐指数
1
解决办法
6004
查看次数

使用"溢出隐藏"时垂直对齐

我没有运气试图调整一些文字.我测试了溢出隐藏值删除但仍然无法让它看起来我想要的.

这是一个codepen页面示例:http://codepen.io/anon/pen/oXrPGJ

HTML

<div>
 <article>
  <section>
   <h2 class="colourtitle">
    <img class="sideimage" src="http://placehold.it/256x256">
    I'm glad I wrap, wish I was vert mid
   </h2>
  </section>
 <article>
</div>
Run Code Online (Sandbox Code Playgroud)

和CSS

html {
    color: #222;
    font-size: 1em;
    line-height: 1.4;
}

body {
    font: 16px/26px Helvetica, Helvetica Neue, Arial;
}

h2 {
    padding-top: 1.5em !important;
    overflow: hidden !important;
}

.colourtitle {
    border-bottom-style: solid;
    border-bottom-color: red;
    border-bottom-width: 10px;
    padding: 5px 0 0 0;
}

.sideimage {
    display: inline-block;
    margin-right: 0.5em;
    max-width: 70px; 
    padding-top: 10px;
    border-right-style: solid; …
Run Code Online (Sandbox Code Playgroud)

html css vertical-alignment

3
推荐指数
1
解决办法
465
查看次数

如何在JavaScript中切换截断文本?

这里的例子: 在此处输入图片说明

如何将文本从“截断”切换为“全文”?

就像我想在一个人单击“阅读更多”按钮时切换全文,并在单击“隐藏文本”按钮时也隐藏文本

片段:

var textHolder = document.querySelector('.demo');
var btn = document.querySelector('.btn');


function Truancate(textHolder, limit) {
  let txt = textHolder.innerHTML;
  if (txt.length > limit) {
    let newText = txt.substr(0, limit) + ' ...';
    textHolder.innerHTML = newText;
  }
}

Truancate(textHolder, textHolder.offsetWidth / 10);



function toggleText() {
  // here i want to show full text...
  // and also -> btn.innerHTML = 'Hide Text' | 'Show Text;
}


btn.addEventListener('click', toggleText);
Run Code Online (Sandbox Code Playgroud)
<section class="demo" id="demo">
  Let's truncate a long line of text so that the …
Run Code Online (Sandbox Code Playgroud)

javascript html5 css3

3
推荐指数
1
解决办法
907
查看次数

Bootstrap 在固定高度 div 内下拉

我在具有可滚动内容的固定高度 div 中有一个引导下拉菜单(overflow-y: scroll;)。我的问题是,当菜单变得更长时,它隐藏在其父 div 内,因为它具有垂直滚动条。我想显示它的全尺寸(在其父级之上)。z-index 不适用于此。

.highlights-box {
  background-color: #f5f5f5;
  border: 1px solid #e0e0e0;
  font-size: 17px;
  font-family: camberia;
  padding-left: 0px;
  padding-right: 0px;
  margin-top: 7px;
}

.highlights-box h1 {
  font-family: camberia;
  text-align: center;
  padding-top: 10px;
  padding-bottom: 10px;
  font-size: 24px;
  font-weight: normal;
}

.unesco {
  padding-top: 2px;
  padding-bottom: 2px;
  border-top: 1px solid #e0e0e0;
  border-bottom: 1px solid #e0e0e0;
  padding-left: 20px;
  font-size: 18px;
}

.city-heading {
  font-weight: bold;
  text-decoration: underline;
  text-align: center;
  padding-top: 7px;
  padding-bottom: 7px;
  text-transform: uppercase;
}

.monuments { …
Run Code Online (Sandbox Code Playgroud)

html css twitter-bootstrap

2
推荐指数
1
解决办法
1875
查看次数