我想知道为什么Boostrap选择rem而em不是px新版本的Boostrap 4.
一些变量示例:
$font-size-h1: 2.5rem !default;
$font-size-h2: 2rem !default;
$font-size-h3: 1.75rem !default;
$mark-padding: .2em !default;
Run Code Online (Sandbox Code Playgroud)
使用em和rem是一个很好的做法:
margin: 0;
padding: 0;
bottom: 0px;
width: 100%;
Run Code Online (Sandbox Code Playgroud)
我只是好奇我在网上找不到这个,所以我要问的原因.
我尝试使用 - 连字符创建一些控制器,模型和视图,但我总是得到PHP错误,所以我现在使用下划线.
所以我的网址是: http:// localhost:8888/ci/index.php/get_artist_discography/artist_name
我想是这样的: http:// localhost:8888/ci/index.php/get-artist-discography/artist-name
它可能有url - 在codeigniter连字符?
我的代码:
/控制器:
<?php
include (APPPATH.'/libraries/REST_Controller.php');
class get_artist_discography extends REST_Controller {
function artist_name_get(){
$data = new stdClass();
$this->load->model('artist_model');
$data = $this->artist_model->getAll();$this->response($data, 200);
}
}
Run Code Online (Sandbox Code Playgroud)
/楷模:
<?php
class artist_model extends CI_Model {
function getAll(){
$q = $this->db->query("SELECT artist_discography,artist_name from music");
if($q->num_rows() > 0) {
foreach ($q->result() as $row) {
$data [] = $row;
}
return $data;
}
}
}
Run Code Online (Sandbox Code Playgroud) 我有一个关于 sass 中的@content 的小问题
我仍然不太明白如何使用它,就像我阅读的内容一样,如果您想使用 mixin 并在那里插入其他内容。
我的问题是:如果没有工作,为什么我需要使用@content?
我的例子:
@mixin context--alternate-template {
margin: 0;
font-size: 14px;
}
.content-sample {
@import context--alternate-template;
background-color: black;
}
Run Code Online (Sandbox Code Playgroud)
输出CSS:
.content-sample {
margin: 0;
font-size: 14px;
background-color: black;
}
Run Code Online (Sandbox Code Playgroud)
我在网上看到的样本:
@mixin context--alternate-template {
margin: 0;
font-size: 14px;
@content
}
.content-sample {
@import context--alternate-template;
background-color: black;
}
Run Code Online (Sandbox Code Playgroud)
输出CSS:
.content-sample {
margin: 0;
font-size: 14px;
background-color: black;
}
Run Code Online (Sandbox Code Playgroud)
所以是的,如果没有工作,为什么我需要在 mixin 中插入 @content 。
我的select2工作得很好,我只有一个小虫子,选择框中的箭头向下图标没有显示,你知道为什么这些人吗?

这让用户有点困惑我尝试找到这个bug,但是我无法解决这个错误,请问各位帮帮我吧?代码在这里不起作用,但它在jsfiddle链接中工作.
jsfiddle:http://jsfiddle.net/yszv1ob2/
$("#e1").select2();Run Code Online (Sandbox Code Playgroud)
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js"></script>
<script src="http://cdnjs.cloudflare.com/ajax/libs/select2/3.2/select2.min.js"></script>
<link rel="stylesheet" href="http://cdnjs.cloudflare.com/ajax/libs/select2/3.2/select2.css">
<select multiple id="e1" style="width:300px">
<option value="AL">Alabama</option>
<option value="Am">Amalapuram</option>
<option value="An">Anakapalli</option>
<option value="Ak">Akkayapalem</option>
<option value="WY">Wyoming</option>
</select>Run Code Online (Sandbox Code Playgroud)
我正在使用WOW.js和animate.css,现在我将我的CSS运行到Infinite.我想知道如何让我的课程运行3秒钟停止并重新开始无限?
我的HTML:
<img src="images/fork.png" class="fork wow rubberBand" >
Run Code Online (Sandbox Code Playgroud)
我的CSS课程:
.fork {
position: absolute;
top: 38%;
left: 81%;
max-width: 110px;
-webkit-animation-iteration-count: infinite ;
-webkit-animation-delay: 5s;
}
Run Code Online (Sandbox Code Playgroud)
解决方案可以是JS或CSS3.
如何在离子v2的标题中插入徽标?
<ion-header>
<ion-navbar>
<ion-title></ion-title>
</ion-navbar>
</ion-header>
Run Code Online (Sandbox Code Playgroud) 我做了一个带有过渡效果的侧边栏菜单。
问题是,当我点击图标时,侧边栏有点挤压夹心字母。
$('.fa-bars').on('click', function clickHandler(e) {
e.preventDefault();
$('.magic-container').toggleClass('closed');
});Run Code Online (Sandbox Code Playgroud)
.sidebar-shrink {
height: 100%;
overflow-y: auto;
background: #000;
}
.magic-container.closed .sidebar-left-nav {
-webkit-transition: width 0.3s;
transition: width 0.3s;
width: 0;
padding: 0;
}
.magic-container.closed .col-md-10 {
-webkit-transition: width 0.3s;
transition: width 0.3s;
width: 100%;
}Run Code Online (Sandbox Code Playgroud)
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
<link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.6.3/css/font-awesome.min.css" rel="stylesheet"/>
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet"/>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<body>
<div class="container-fluid magic-container">
<div class="col-md-2 sidebar-left-nav">
<div class="sidebar-shrink">
<ul>
<li>
<a href="#">Hello World<i class="pull-right fa fa-bullhorn" aria-hidden="true"></i></a>
</li>
<li>
<a href="#">Hello World<i class="pull-right fa fa-bullhorn" …Run Code Online (Sandbox Code Playgroud)升级我的 Ubuntu 服务器后,我尝试打开我的 WordPress 网站,我在 error.log 中收到此错误
AH00124:由于可能的配置错误,请求超出了 10 个内部重定向的限制。如有必要,请使用“LimitInternalRecursion”增加限制。使用“LogLevel debug”获取回溯。
当我打开网站时收到消息。
<?php
/**
* Front to the WordPress application. This file doesn't do anything, but loads
* wp-blog-header.php which does and tells WordPress to load the theme.
*
* @package WordPress
*/
/**
* Tells WordPress to load the WordPress theme and output it.
*
* @var bool
*/
define('WP_USE_THEMES', true);
/** Loads the WordPress Environment and Template */
require( dirname( __FILE__ ) . '/wp-blog-header.php' );
Run Code Online (Sandbox Code Playgroud)
我尝试了下面这两个链接,但我的 .htaccess 不同,所以不起作用。 …
我创建了一个mixin来轻松操作图像并替换,现在我的应用程序正在增长,我不知道如何改进此代码.
基本上我有一个包括: @include img-replace("logo.png", 104px, 47px, inline-block); 我简单地改变图像的名称并定义像素的宽度和高度.
我想改变它,因为现在,一些开发人员只想更改图像名称而不用担心大小了解?
在这种情况下,图像具有:宽度:104px和高度:47px,因此他们不再担心它,因为下一个图像可以更大或更小.
那么这个有什么解决方案吗?谢谢.
$path--rel : "../images";
@mixin img-replace($img, $w, $h, $disp: block) {
background-image: url('#{$path--rel}/#{$img}');
background-repeat: no-repeat;
width: $w;
height: $h;
display: $disp;
}
.site-logo {
@include img-replace("logo.png", 104px, 47px, inline-block);
margin-top: 8px;
margin-left: 6px;
}
Run Code Online (Sandbox Code Playgroud) 我通过Magento Admin界面创建了一个CMS页面,并在其中放入以下代码:
{{block type="catalog/product_list" name="home.catalog.product.list" alias="products_homepage" category_id="3" template="catalog/product/list.phtml"}}
Run Code Online (Sandbox Code Playgroud)
这显示了ID为3的类别的产品.
我的magento配置为每页显示9个产品.在该类别中,有30个产品.
在我的类别页面上,我可以看到一个分页器,这在CMS页面上不会发生.我究竟做错了什么?
css ×6
sass ×3
javascript ×2
jquery ×2
.htaccess ×1
apache ×1
block ×1
codeigniter ×1
css3 ×1
em ×1
html ×1
ionic2 ×1
magento ×1
mod-rewrite ×1
pagination ×1
php ×1
url ×1
wordpress ×1
wow.js ×1