我已经在本地机器(Centos 7)上安装了 WordPress。如果没有漂亮的 URL,它运行良好。
我试图让它发挥作用:
在 /etc/httpd/conf/httpd.con 下设置 Allowoverride All 并重新启动 httpd 服务。
使用以下代码行在 WordPress 目录中创建 .htaccess 文件:
<IfModule mod_rewrite.c>
重写引擎开启
重写基数 /
重写规则 ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
重写规则。/rakesh/index.php [L]
</IfModule>
结果我得到“未找到
在此服务器上找不到请求的 URL /index.php。”
须藤 chown apache /var/www/html/wordpress/.htaccess 须藤 chmod 777/var/www/html/wordpress/.htaccess
.
我希望我的日期选择器位于页面中间,例如.我所拥有的那条线:<div class="center-block text-center datepicker"></div>
显然,center-block和text-center我已经试过-但也不能改变什么.并且通过偏移它使它靠近中心而不是完全中心对齐.
我需要做什么?
谢谢
<div class='row'>
<div class='col-sm-12'>
<div class='page-header page-header-with-icon mg-t'> <i class='fa-icon-calendar'></i>
<h2>Calendar</h2>
</div>
<div class="row">
<div class="col-sm-4 col-sm-offset-4">
<div class="center-block text-center datepicker"></div>
</div>
</div>
</div>
</div>
Run Code Online (Sandbox Code Playgroud) 我有以下文件夹设置:
Main
css
stylesheet.css
sub
example
index.php
index.php
Run Code Online (Sandbox Code Playgroud)
如何链接stylesheet.css到中的index.php文件example?
<link rel="stylesheet" type="text/css" href="css/stylesheet.css">
这仅适用index.php于“主要”部分。
这有点难以解释,这就是为什么我在谷歌上也找不到答案。
我正在使用 Bootstrap 3,并且需要全宽背景图像。在那 2 个透明彩色背景之上。我制作了一个示例图片以使其更清楚:
1+2:组合透明彩色背景
3+4:组合透明彩色背景
1+2+3+4:组合背景图(最底层)
有谁知道这是否可能以及如何实现?感谢您的帮助!
我有一个徽标,我希望将它放在第一排的容器右侧.首先我写了这段代码:
<div class="container">
<div class="row">
<div class="col-md-3">
<img src="../Images/logo.png" alt="Logo"/>
</div>
<div class="col-md-9">
</div>
</div>
</div>
Run Code Online (Sandbox Code Playgroud)
并且徽标显示在第一行的左侧,带有一些边距.现在pull-right我div像这样添加类:
<div class="col-md-3 pull-right">
<img src="../Images/logo.png" alt="Logo"/>
</div>
Run Code Online (Sandbox Code Playgroud)
并且徽标与浏览器窗口的右侧对齐,没有任何边距.我如何在第一排的右侧放置徽标,如左侧?
谢谢
我想设计一个与下图相似的形状(圆形和矩形之间的效果):
我知道圆形的形状是使用border-radius设计的,矩形的形状是用一些无序的列表设计的,它有样式display:block.但我无法理解如何将圆圈保持在矩形上,以便看起来矩形的某些部分被圆形切割成圆形(圆形和矩形之间的白色空间).
我尝试了盒子阴影,轮廓,溢出等,但它不起作用.
任何人都可以告诉我如何设计像图像一样的形状?- 谢谢
我flexbox用于我的布局,在完成Flexbox Froggy之后,我尝试得到以下对齐方式:
我的想法如下:
<div>)需要在列中流动:flex-direction: column;align-content: flex-start;align-self: flex-end;<div class="container">
<div class="box1">
box 1
</div>
<div class="box2">
box 2
</div>
<div class="box3">
box 3
</div>
</div>
Run Code Online (Sandbox Code Playgroud)
用CSS
.container {
display: flex;
flex-direction: column;
align-content: flex-start;
}
.box3 {
align-self: flex-end;
}
Run Code Online (Sandbox Code Playgroud)
但它不起作用 - 看起来第三个框被推(flex-end)向右而不是向下.
我的理解是align-self处理相对于容器的异常("容器从顶部对齐所有东西,但我,我自己,将对齐到底部").不是这样吗?
我正在尝试将下拉菜单与中心对齐,我正在使用 Bootstrap 4。
我正在关注这个例子:
[![示例下拉菜单]](https://i.stack.imgur.com/nImrY.png)
这就是我得到的:
[![我的情况]](https://i.stack.imgur.com/yLZJB.png)
这是我的代码:
<div class="container">
<div class="row">
<div class="col-md pl-4 user-dropdown text-center">
<div class="dropdown btn-group">
<a class="navbar-brand dropdown-toggle" href="#" id="bd-versions" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"><i class="fas fa-user"></i></a>
<ul class="dropdown-menu">
<li>
<a href="{{ route('logout') }}" onclick="event.preventDefault(); document.getElementById('frm-logout').submit();">
Logout
</a>
<form id="frm-logout" action="{{ route('logout') }}" method="POST" style="display: none;">
{{ csrf_field() }}
</form>
<hr>
</li>
<li><a href="{{ route('user.profile') }}">My Profile</a></li>
</ul>
</div>
</div>
<div class="col-md">
<span><a class="navbar-brand" href="#"><i class="fas fa-shopping-cart"></i></a></span>
</div>
<div class="col-md">
<span><a class="navbar-brand" href="#"><i class="fas fa-heart"></i></a></span>
</div>
</div> …Run Code Online (Sandbox Code Playgroud) 我正在应用 Flexbox 概念,但我在这里遇到了一些困难,我应用display: flex;并将方向应用为列。
现在,由于主轴是列,所以我在 和justify-content之间创建了空间,但是这个空间不应用于在navbar和section-main之间创建空间footer。
.page-container {
display: flex;
flex-direction: column;
justify-content: space-between;
}
.navbar {
display: flex;
flex-direction: row;
justify-content: space-between;
}
.section-main {
display: flex;
flex-direction: row;
justify-content: space-between;
}Run Code Online (Sandbox Code Playgroud)
<html>
<body>
<div class="page-container">
<div class="navbar">
<div class="brand">
Oka brand
</div>
<div class="nav-buttons">
nav buttons
</div>
</div>
<div class="section-main">
<div class="left-nav">
left nav
</div>
<div class="middle-section">
middle section
</div>
<div class="right-nav">
nav icons
</div>
</div>
<div class="footer"> …Run Code Online (Sandbox Code Playgroud)预期输出应至少有 2 行高
\n\n\n\n我想保留text-overflow: ellipsis财产
<div style="min-height: 128px;\r\n border-radius: 7px;\r\n box-shadow: 0 2px 4px 0 rgba(210, 210, 210, 0.5);\r\n border: solid 0.3px rgba(26, 25, 25, 0.15);\r\n background-color: #ffffff;\r\n width: 268px;\r\n margin-bottom: 13px;">\r\n\r\n\r\n <div style=" width: 100px; font-family: Roboto;\r\n font-size: 13px;\r\n font-weight: normal;\r\n font-style: normal;\r\n font-stretch: normal;\r\n line-height: normal;\r\n letter-spacing: 0.29px;\r\n white-space: nowrap;\r\n overflow: hidden;\r\n text-overflow: ellipsis;\r\n padding-top: 5.6px;\r\n height: 49px;">\r\n Can we make this upper case? and also remove the word and\xe2\x80\x99? Can …Run Code Online (Sandbox Code Playgroud)css ×9
html ×7
flexbox ×2
bootstrap-4 ×1
centos ×1
css-shapes ×1
css3 ×1
php ×1
whitespace ×1
wordpress ×1