English 中文(简体)
需要帮助复制这种非常简单的盒式效应,以超文本/CSS
原标题:Need help replicating this fairly simple box effect in HTML/CSS
  • 时间:2012-05-11 00:14:52
  •  标签:
  • html
  • css
最佳回答

因此,鉴于您的标志和标准字体选择,我重复了这一说法,但布局应当正确。

在箱子内设置一个绝对宽度,并给他们一个<条码>条码:0;似乎是直截了当的,在休假审查要素中增加了一些附加条件,使之更接近平均。

Css:

* { font-family: Tahoma; }   

.product-score-cta { right:0; left: 0; bottom:5px; font-size: 14px; text-decoration: none; color: #EEE;}
            .ourscore {bottom:12px; font-size: 18px; font-style: italic;}
            .totalscore {top:10px; font-size:70px; line-height:70px;width:130px; position: absolute;}
            .ourscore,.totalscore,.product-score-cta {position:absolute; width: 130px; left: 0px;}
        .score {
            height:115px;
            color:white;
            background:#f48b1b;
            position:relative;
            }

        .product-score-box {
            display: block;
            position: absolute;
            top:20px;
            right:10px;
            color: white;
            font-family:  DINCond-MediumRegular ;
            background: black;
            text-align: center;
            z-index: 20;
            overflow: hidden;
            font-size: 16px;
            line-height: 100%;
            width:130px;
            height:140px;
            }   ​

http://www.ohchr.org。

问题回答

1) remove the absolute positioning for .totalscore and .ourscore 2) position score relatively 3) position the "ourscore" label absolutely

Here it is: http://jsfiddle.net/hammerbrostime/PGKNU/





相关问题
CSS working only in Firefox

I am trying to create a search text-field like on the Apple website. The HTML looks like this: <div class="frm-search"> <div> <input class="btn" type="image" src="http://www....

image changed but appears the same in browser

I m writing a php script to crop an image. The script overwrites the old image with the new one, but when I reload the page (which is supposed to pickup the new image) I still see the old one. ...

Firefox background image horizontal centering oddity

I am building some basic HTML code for a CMS. One of the page-related options in the CMS is "background image" and "stretch page width / height to background image width / height." so that with large ...

Separator line in ASP.NET

I d like to add a simple separator line in an aspx web form. Does anyone know how? It sounds easy enough, but still I can t manage to find how to do it.. 10x!

热门标签