导航:首页 > 文字图片 > 图片文字布局

图片文字布局

发布时间:2022-01-07 10:02:40

㈠ CSS 图片和文字如何实现并排

无论你右边文字有多少,始终都会在图片右边,不会再跑到图片下边了。
代码如下,好好研究:
<style type="text/css">
.item .pic { float:left;margin-right:10px;width:100px;height:100px; }
.item .content {float:left;width:500px;}
</style>
<div class="item">
<div class="pic"><img src="a.jpg"></div>
<div class="content">文字部分</div>
</div>由于这个功能都要使用到浮动float,就需要对左右两边的模块都要定义款度,不然的话,默认的都是100%,是填充整个外部容器,是无论如何都不能左右显示了。

㈡ 这种关于文章的文字和图片页面是怎么布局,求解

<style type="text/css">
.all{ width:599px; height:auto; margin:0 auto; border:2px solid #666; float:left; padding:10px; font-size:12px; color:#666666; line-height:24px;}
.top{ width:599px; height:50px; line-height:50px; float:left; font-size:16px; font-family:"微软雅黑"; font-weight:bold; text-align:center}
.main_1{ width:599px; height:30px; float:left}
.main_2{ width:250px; height:30px; line-height:30px; float:left; color:#666;}
.main_3{ width:100px; height:30px; line-height:30px; float:left; color:#ff0000;}
.main_4{ width:100px; height:30px; line-height:30px; float:right;}
.main_5{ width:599px; height:auto; float:left; background:url(123.jpg) no-repeat scroll left top;}
.main_6{ width:599px; height:300px; float:left;}
p{ color:#ff0000; margin:5px 0;}
.span{ font-weight:bold; color:#333}
a{ color:#666; text-decoration:none; padding:0 15px;}
a:hover{ color:#ff0000; text-decoration:none;}
</style>
<div class="all">
<div class="top">这里是标题</div>
<div class="main_1">
<div class="main_2">浏览量等等…………,宽度自己调整</div>
<div class="main_3">宽度自己调整</div>
<div class="main_4">分享</div>
</div>
<p><span>标签:</span><a href="#" target="_self">链接</a> <a href="#" target="_self">链接</a></p>
<div class="main_5">css中的背景图片自己上传上去,然后定位就行了。。。css中的背景图片自己上传上去,然后定位就行了。。。css中的背景图片自己上传上去,然后定位就行了。。。css中的背景图片自己上传上去,然后定位就行了。。。css中的背景图片自己上传上去,然后定位就行了。。。css中的背景图片自己上传上去,然后定位就行了。。。</div>
<p>图片上面的标题</p>
<div class="main_6"><img src="" border="0"></div>
</div>

㈢ 图片文字css布局问题

花了半个小时帮你写了这些代码,真不容易,几乎和你效果图一模一样,兼容任何浏览器,代码和图片已经过测试,测试成功100%,具体代码如下:

<!DOCTYPEhtmlPUBLIC"-//W3C//DTDXHTML1.0Transitional//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<htmlxmlns="http://www.w3.org/1999/xhtml">
<head>
<metahttp-equiv="Content-Type"content="text/html;charset=gb2312"/>
<title>SNS</title>
<styletype="text/css">
<!--
body{
font-family:Arial;
padding:0;
margin:10px;
color:#999;
font-size:12px;
background-color:#323232;
}
a{
cursor:pointer;
text-decoration:none;
}
.fr{
float:right;
}
.cl{
clear:both;
}
.c4{
color:#444;
}
.c6{
color:#666;
}
.blue{
color:#2a7ad2;
}
.bluea{
color:#2a7ad2;
}
.bluea:hover{
color:#2a7ad2;
text-decoration:underline;
}
.yellow{
color:#ffc806;
}
.yellowa{
color:#ffc806;
}
.yellowa:hover{
color:#ffc806;
text-decoration:underline;
}
.mt30{
margin-top:30px;
}
.mr10{
margin-right:10px;
}
-->
</style>
</head>

<body>

<!--头像-->
<divclass="fr">
<imgsrc="header.png"width="40px"height="40px"/>
</div>
<!--头像/-->

<!--登录信息-->
<divclass="frmr10">
<divclass="fr">
<span>Loggedinas<b>Admin</b></span>
<spanclass="c4">|</span>
<spanclass="blue"><ahref="#">Settings</a></span>
<spanclass="c4">|</span>
<spanclass="blue"><ahref="#">Logout</a></span>
</div>
<divclass="frcl">
<spanclass="c6">Youhave</span>
<spanclass="yellow"><ahref="#"><b>1</b>newmessage!</a></span>
</div>
</div>
<!--登录信息/-->

<!--语言切换-->
<divclass="frclmt30">
<b>English</b>·<spanclass="blue"><ahref="#">Spanish</a></span>·<spanclass="blue"><ahref="#">German</a></span>
</div>
<!--语言切换-->
</div>
</body>
</html>


注:header.png为40x40的头像。

㈣ word怎么编排文字和图片的布局

点击插入的图片,会出现“图片”工具栏,点击其上的“文字环绕”,剩下的你自己就会做了,呵呵。祝你操作顺利。

㈤ CSS布局文字在图片上怎么写

<style>
.img{position:relative;}
.imgp{width:100%;height:100px;text-align:center;position:absolute;top:40%;font-size:14px;line-height:30px;}
</style>

<divclass="img">
<imgsrc="1.jpg"alt="">
<p>
hello<br/>hello<br/>hello
<p>

</div>

文字间记得加<br /> 怎么没显示

㈥ 在一个div 里面有左边图片左偏边下方是文字,右边是文字怎么布局,像图片这样的布局怎么布局,求解

就拿知识那一块为例,图标与知识放在一个div内,右边的文字连再放在一个div内,之前2个div是平级的,都设定好宽度左浮动,然后再再里面做细分就行了
其实div+css有点像我们小时候玩的俄罗斯方块积木,这需要我们发挥想象来排列div的组合方式

㈦ html怎么让文字和图片并排

同一个div中的图片和文字一起左右居中的话div中的图片设置display:block;margin:auto;然后给div设置text-align:center就好,记得给div设置宽度。想要垂直也居中就不给div设置高度,设置相等padding-top和padding-bottom就行

㈧ css中图片与文字布局

您好,给图片一个浮动样式效果,便可达到你的要求。或者图片设置一个层浮动,文字也设计一个层浮动,便可。都向左浮动。

㈨ 怎么用CSS+DIV在图片上布局文字

div是将网页区块化处理,css是给对应的div应用对应的样式,你所说的图片上进行文字处理,有两种办法,:1将图片变成该区块的背景图,<div style="background:url(images/index8_29.gif) repeat-y;">然后在这个区块中你就可以自己定义文字了,比如<div style="fontsize:12px;colour:#000000;margin-left:auto;
margin-right:auto;">所要放的文字</div></div>

㈩ div+css 文字图片布局

你好,只要设置左侧图片左浮动就可以了,右侧p标签设置overflow:hidden;

大概代码:

img{float:left;margin-right:10px;}
p{overflow:hidden;}
阅读全文

与图片文字布局相关的资料

热点内容
三小孩可爱图片 浏览:232
16英朗价格及图片 浏览:571
更简单的装饰花图片 浏览:371
欧美男生纹身社会图片 浏览:189
如何将图片设计为超链接 浏览:673
周杰伦晴天图片高清图片 浏览:381
画画图片芭蕾女孩 浏览:502
链接里边怎么删除图片 浏览:66
word图片怎样裁剪成所需大小 浏览:741
藏獒可爱图片大全 浏览:549
素描卡通少女图片简单画 浏览:971
男生头像雕刻图片 浏览:149
男生帅气图片霸道总裁 浏览:861
好伙食文字图片 浏览:665
图片如何按照预订尺寸打印 浏览:649
有猫的动漫女生头像图片 浏览:532
手好看的男生图片 浏览:837
有图案衣服图片 浏览:411
原宿女生图片素材 浏览:128
夏天女生长发发型图片 浏览:546