css - 如何在 :after selecter stay on background and correct position? 中制作背景图像

标签 css wordpress

我想在前后制作一个以图像为背景的 block 引用。 :before 不是问题,但是使用 :after 选择器,图像会保留在前景中。文本消失...

我用 css 尝试了不同的解决方案,比如 display inline-block;giving the paragraph index:99 等等。

CSS:

blockquote p:after{
content:"";
 height:50px;
 width:50px;
 background:url("https://proef-domein.nl/chiropractic/wp-content/uploads/2019/06/quotes.png");
 margin-left:-30px;
 z-index:1;
 position:absolute}

位置正确,但图像停留在文本上方而不是文本下方。

最佳答案

试试这个它在我的本地安装上有效:

z-index:-1;

关于css - 如何在 :after selecter stay on background and correct position? 中制作背景图像,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56888407/

相关文章:

wordpress - Woocommerce - 删除购物车运输中的国家/地区字段

CSS Styles 不小心删除了我在 wordpress 中的滚动条

php - 从最大的 SQL 和更改 CSS

html - 创建一个恒定的脉冲动画

jquery - 使我的网站的某些部分更具移动性和不同的屏幕分辨率大小友好

PHP + CSS : Output Options Framework Content

php - 为什么别人看不到我的wordpress网站

html - 带有额外列的列表

html - 网页周围的边框?

WordPress 永久链接不起作用