Home > Web Front-end > HTML Tutorial > 背景图片文字布局问题_html/css_WEB-ITnose

背景图片文字布局问题_html/css_WEB-ITnose

WBOY
Release: 2016-06-24 11:36:08
Original
944 people have browsed it


这个效果的代码:

<div style=" background:url(图片路径); background-size:100% 100%;width:238px; height:159px; vertical-align:text-bottom;">                                        <div style="background:#757575; filter:alpha(opacity=50); -moz-opacity:0.50; opacity:0.50; height:30; line-height:30px;">                                            测试案例                                        </div>                                	</div>
Copy after login

现在要实现成下面这图片的效果:


回复讨论(解决方案)

就是把上面这条换来下面,我用了vertical-align:text-bottom;  但没有效果


                                        

                                            测试案例
                                        

                                    
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template