css - 侧 Angular 标记 (CSS)

标签 css

我有一个 HTML 页面,上面列出了许多照片。我正在寻找一些有关如何执行 CSS 的帮助,以便某些照片具有顶 Angular “标记”,例如此处称为“精选”的红色条纹 -

http://www.logospire.com/logos/3922

enter image description here

我可以用谷歌搜索这是什么,但我不知道关键字。希望有任何提示和指示。

最佳答案

在您链接的页面上,它是通过背景图像解决的,因此它只是一个图像。您可以使用 Chrome Inspector/Firebug/IE Developer Tools/DragonFly/等来检查元素。

HTML:

<a id="featured" href="/?sort=featured"></a>

CSS:

#featured {
    display: block;
    width: 94px;
    height: 78px;
    background: url(/images/featured_bg.png) no-repeat;
    position: absolute;
    z-index: 10;
    top: -2px;
    left: -2px;
}

您还可以使用CSS3 Transforms (特别是 Rotation )来实现这样的目标。

关于css - 侧 Angular 标记 (CSS),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11650235/

相关文章:

javascript - 如何根据元素位置调用函数?

html - 为什么我的链接不显示在 IE 9 中?

javascript - 如何使用键盘快捷键打开弹出窗口?

html - 语义 UI 图标字体未加载

html - 页脚的网站正在创建水平滚动条

jquery - IE8 和 IE9 的 Fancybox 样式问题

jquery - jQ根据周围的div动态设置div高度

html - 如何在 Safari 和移动设备上防止 overflow-x

javascript - 出于某种原因,我的页脚不太适合移动设备

javascript - 无法使用 javascript 回调更改正文背景颜色