我怎样才能@font-face在CSS中使用超过规则?
我已将其插入到样式表中:
body {
background: #fff url(../images/body-bg-corporate.gif) repeat-x;
padding-bottom: 10px;
font-family: 'GestaRegular', Arial, Helvetica, sans-serif;
}
@font-face {
font-family: 'GestaReFogular';
src: url('gestareg-webfont.eot');
src: local('?'),
url('gestareg-webfont.woff') format('woff'),
url('gestareg-webfont.ttf') format('truetype'),
url('gestareg-webfont.svg#webfontg8dbVmxj') format('svg');
}
Run Code Online (Sandbox Code Playgroud)
这目前仅适用于网站上的整个文本.但是,我想指定h1使用不同的字体.我怎样才能做到这一点?
我有一个在线托管的网页,我希望有可能我可以使用一些JavaScript将IFRAME插入到另一个网页上.
这将是最好的方式,我只是将我的网页URL添加到JavaScript并且它适用于所有浏览器?
谢谢
我已经创建了一个非常简单的网页布局,可以在这里看到:http://s361608839.websitehome.co.uk/greengold/www/index.html,你可以看到,似乎有一个问题.div #rightcol似乎被左侧顶部div(#leftcolbanner)向下推.
#leftcolbanner的CSS是:
#leftcolbanner{
width: 707px;
height: 266px;
float: left;
background: url(../images/banner_home.gif) no-repeat;
margin: 20px 0 20px 20px;
-webkit-border-radius: 5px;
-moz-border-radius: 5px;
border-radius: 5px;
border: 1px solid #e1dbce;
}
Run Code Online (Sandbox Code Playgroud)
和#rightcol:
#rightcol{
width: 190px;
background: #f4f2ec url(../images/bg_rightcol.gif) no-repeat right bottom;
float: right;
min-height: 550px;
padding: 25px;
-moz-border-radius-topleft: 0px;
-moz-border-radius-topright: 5px;
-moz-border-radius-bottomright: 5px;
-moz-border-radius-bottomleft: 0px;
-webkit-border-radius: 0px 5px 5px 0px;
border-radius: 0px 5px 5px 0px;
border-left: 1px solid #e1dbce;
}
Run Code Online (Sandbox Code Playgroud)
#leftcolbanner的宽度不应该是为什么#rightcol被推下来的问题.这似乎是我经验中唯一的原因,但这次并非如此.
任何人都可以看到任何我看不到的东西吗?
非常感谢
在我正在处理的网页上,我有一个固定的#top部分,其中包含导航,导致下面的内容部分隐藏在其后面.
页面是这样的:http://s361608839.websitehome.co.uk/pt-build/templatebuild/
我已经尝试将margin-top添加到#slider,并将margin-bottom添加到#top以尝试将彼此分开,但这些都没有奏效.
有任何想法吗?
是什么和有没有基于DIV中的文本量使用CSS缩放文本的方法.
我在http://www.directiongroup.com/tweethearts/上创建了这个页面,文本的CSS是(固定大小为32px):
.jta鸣叫文本
{
color: #ed1c24;
font-size: 32px;
text-transform: uppercase;
line-height: 30px;
font-weight: normal;
font-family: 'BebasNeueRegular', Arial, Helvetica, sans-serif;
text-shadow: 0px 1px 0px #FFFFFF;
}
Run Code Online (Sandbox Code Playgroud)
非常感谢
使用CSS,我可以将div类设置为段落上的某些文本,将其放到下面的行中吗?
我试过漂浮:左; 它将文本移动到段落的开头,这是一个好的开始,因为我希望左边的文本,但我需要在下面的行.
这是HTML:
<div class="tweet">
<ul class="tweet_list">
<li class="tweet_odd">
<span class="tweet_text">This is a tweet</span>
<span class="tweet_time">1 minute ago</span>
</li>
</ul>
</div>
Run Code Online (Sandbox Code Playgroud)
谢谢
我有一个带有框阴影的div框,其中包含以下CSS:
-moz-box-shadow: 1px 1px 15px #415a68;
-webkit-box-shadow: 1px 1px 15px #415a68;
-khtml-box-shadow: 1px 1px 15px #415a68;
box-shadow: 1px 1px 15px #415a68;
Run Code Online (Sandbox Code Playgroud)
我怎样才能制作盒子阴影只适用于div的左,右和底?
如何为li id定义样式?它的工作方式与李式相同吗?
例如
<li id="news" class="section_wrapper"></li>
Run Code Online (Sandbox Code Playgroud) 我有一个HTML表单,我把它放在一起......
有一个问题"你能参加吗?" 带有"是"和"否"复选框.
很明显,提交表单的人是否参加,所以我希望表单只允许选择一个复选框.
这是HTML:
<p>Can you attend?</p>
<label>
<input type="checkbox" name="attendance" value="checkbox" id="Yes" />
Yes</label>
<label>
<input type="checkbox" name="attendance" value="checkbox" id="No" />
No</label>
Run Code Online (Sandbox Code Playgroud)
我的代码需要什么?我猜一些JavaScript?
谢谢
我已经在http://edge.directiongroup.co.uk/建立了这个网站,在主页上你可以看到正确的div类'.sidebar'正在以某种方式被推下来.
在另一页http://edge.directiongroup.co.uk/content-marketing/上没有问题.
它似乎是由主页上的#edge_header引起的,但我无法弄清楚我需要改变什么才能使正确的.sidebar div正确定位在两个页面上.
似乎导致问题的#edge_header的CSS在这里: -
#edge_header {
background: url("images/edge_header.png") no-repeat scroll center bottom rgb(255, 255, 255);
width: 618px;
height: 318px;
float: left;
}
Run Code Online (Sandbox Code Playgroud)
堆栈溢出通常是最后的问题,通过向你们提出这个问题,任何人都可以帮忙吗?
谢谢!