=======
文字环绕
=======
<style>
div {
width:300px;
border:1px solid red
}
img {
float:center;
width:100px;
height:100px
}
</style>
<div>
<img src="/images/logo.gif" />
绕啊绕啊
绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊 绕啊绕啊
</div>
=======
图片居中
======
<center><img src="img/logo.gif"></center> <!--html-->
==============================================
<!---css-->
========
div{
margin:0 auto;
padding:0px;
}
<div id="logo">
<img src="img/logo.gif">
</div>
CSS的定义:
#logo{width:500px; height:300px;}
#logo img{margin-top:100px; margin-left:150px;}
=================================
可以把让图片先居中,后环绕。
⑵ CSS代码如何设置图片周围字体环绕
1、准备一张图片,新建一个空白html文件
⑶ css文字环绕图片问题
让div.pic右浮动就可以了
div.pic{ float:right;}
不过有些东西还是一确定一下的好,比如你浮动的那张图片,如果尺寸比整个div.post还要大多丑啊。还有,你的div.text里如果有图片,图片是不会从中间折断的,那可能会留下大片空白,可能也会不好看。如果是文字环绕就很好,呵呵
⑷ css怎么实现文字在图片四周环绕
<html>
<head>
<style type="text/css">
img
{
float:right
}
</style>
</head>
<body>
<p>在下面的段落中,我们添加了一个样式为 <b>float:right</b> 的图像。结果是这个图像会浮动到段落的右侧。</p>
<p>
<img src="/i/eg_cute.gif" />
This is some text. This is some text. This is some text.
This is some text. This is some text. This is some text.
This is some text. This is some text. This is some text.
This is some text. This is some text. This is some text.
This is some text. This is some text. This is some text.
This is some text. This is some text. This is some text.
This is some text. This is some text. This is some text.
This is some text. This is some text. This is some text.
This is some text. This is some text. This is some text.
This is some text. This is some text. This is some text.
</p>
</body>
</html>
⑸ CSS求助,文字环绕图片(两张图)
<p><imgclass="pic1"src="http://www..com/img/bdlogo.gif"alt=""/>测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据</p>
<p>测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测</p>
<p>试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据</p>
<p>试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测</p><p><imgclass="pic2"src="http://www..com/img/bdlogo.gif"alt=""/>试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测试数据测</p>
CSS:
.pic1{
float:left;
}
.pic2{
float:right;
}
⑹ css 文字环绕图片
给你的图片写上高度和宽度。
这个为什么我答不出来。不过你可以换个方法来实现。
把图片放在P的外面。或者把图片和文字看成二个DIV块。这样就可以轻松浮动了。不过有可能就是没有环绕效果。
按理说其它的人说的是正确的,而你还不能实现,应该把全部代码发上来看看,可能哪里有误吧。
⑺ div文字这样环绕图片!css怎么定义!
方法很分多,可以把图片和文字分别放在div中然后浮动即可。
我写一个给你,稍等!
<!doctypehtml>
<htmllang="en">
<head>
<metacharset="UTF-8">
<title>Document</title>
<style>
img{
float:left;
}
</style>
</head>
<body>
<div>
<imgsrc="test1.jpg"alt="">
<ul>
<li>地址:***********</li>
<li>电话:1111111111</li>
<li>联系人:大大大大大大</li>
</ul>
</div>
</body>
</html>
你自己再改一改,有用就采纳!
⑻ 高分求css文字环绕图片代码
<style>
.content img {float:left}
</style>
<div class="content">
<img src="1.jpg" /><span>dsddsds<br>fdsfggfgfg<br>sfdsfdfdds</span>
</div>
⑼ CSS 文字环绕图片问题
亲,你尝试下这个代码: .cat-area{ width:343px; float:left} .cat-area .content .img{ margin-right:10px; float:left; display:inline;} .cat-area .content .title { float:left; color:#333; font-size:14px; height:100px; line-height:120px; overflow:hidden} .cat-area .content .des{ float:left; color:#777; font-size:12px; line-height:18px}
标题,,,,,
摘要,,,,,