margin负值的使用
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta content="all" name="robots" />
<title>margin负值的使用</title>
<meta name="keywords" content="DIV+CSS培训,上海DIV+CSS培训,北京DIV+CSS培训,北京Php培训,上海Php培训,div+css教程,DIV+CSS高级手写网站布局重构服务及php网站程序开发,seo优化,http://www.xinran001.com/鑫然网络最专业" />
<meta name="description" content=" 鑫然网络 鑫然网络主要从事上海DIV+CSS培训,北京DIV+CSS培训,北京Php培训,上海Php培训,div+css教程,承接DIV+CSS高级手写网站布局重构及php网站开发,seo优化等服务" />
<style type="text/css">
<!--
*{
margin:0px;
padding:0px;
} ul{
list-style-type:none;
} img {
border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px;margin:0px;padding:0px;
} div {
border-top-width: 0px; padding-right: 0px; padding-left: 0px; border-left-width: 0px; border-bottom-width: 0px; padding-bottom: 0px; margin: 0px; padding-top: 0px; border-right-width: 0px
}
body {
width:100%;font-size:12px;background:#fff;padding: 0px;color:#000;font-family: '宋体','新宋体',arial,verdana,sans-serif;
} form {
border-top-width: 0px; padding-right: 0px; padding-left: 0px; border-left-width: 0px; border-bottom-width: 0px; padding-bottom: 0px; margin: 0px; padding-top: 0px; border-right-width: 0px
} a:link {
color:#003265; text-decoration: underline;
}
a:visited {
color:#003265; text-decoration: underline;
}
a:hover {
color:#fe0000; text-decoration: none;
} .divbody{
padding-left:200px;background:#ccc;
}
.divbody_left{
float:left;width:200px;margin-left:-200px;height:100px;
}
.divbody_right{
width:100%;height:300px;background:#fff;
}
-->
</style>
</head>
<body> <div class="divbody">
<div class="divbody_left">左边盒子</div>
<div class="divbody_right"> <table cellspacing="0" border="1" width="100%">
<tr>
<td>1</td>
<td>2</td>
<td>3</td>
</tr>
<tr>
<td>4</td>
<td>5</td>
<td>6</td>
</tr>
</table> </div>
</div> </body>
</html>
margin负值的使用的更多相关文章
- 深入理解CSS中的margin负值
前面的话 margin属性在实际中非常常用,也是平时踩坑较多的地方.margin折叠部分相信不少人都因为这样那样的原因中过招.margin负值也是很常用的功能,很多特殊的布局方法都依赖于它.它看似简单 ...
- 几个常见的布局的多种实现方式及margin负值总结
第一部分:几个常见的布局实现方式 一.左右两边固定, center中间自适应未知 html代码中 center 部分首先要放在box的最前部分.然后是left,right 圣杯布局: <div ...
- margin负值的几种妙用
1:定位+margin负值实现元素水平垂直居中 div{ position: absolute; z-index: 1; left: 50%; margin-left: -50px; width: 1 ...
- 微吧里的各种margin负值
直在做各种项目接各种需求,但你的代码能力得到提高了吗?不停的项目经历虽然能够增加你的代码行数,但不一定能提升你的代码质量,所以除了构建阶段的代码细扣,项目之后的代码总结是至关重要的. 微吧中除了模块化 ...
- margin负值 – 一个秘密武器
CSS盒模型中,margin是我们老熟悉的一个属性了, 它的负值你用过吗? 你知道 margin负值的秘密武器吗?我们一起看看吧! 1.带竖线分隔的横向列表(例如:网站底部栏目) 传统的分隔符是使用 ...
- 理解margin负值
效果 上和左方的margin负值使元素向上和左方向移动,如果该元素position不是absolute或fixed,这还会导致之后的元素也向上,左移 下和右方的margin负值会缩小下和右方的空间,使 ...
- margin负值的相关应用
1.页面上实现css sprite背景定位效果 其实margin:-40px 0 0 -160px;与background-position:-160px -40px;实现的原理是一致的,而差别就 ...
- 初探Margin负值(转)
相对而言,margin 负值的使用机率在布局中似乎很少,但是我相信一旦你开始掌握就会着迷,接下来我们看看关于margin负值的一些资料: 它是一个有效的属性,至少w3c中明确描述如下:”Negativ ...
- 双飞翼布局的改造 box-sizing和margin负值的应用
box-sizing + margin负值 升级双飞翼布局 一.box-sizing属性 .content-size, .border-size{ width: 200px; height: 100p ...
随机推荐
- 关于Eclipse平台的使用和开发第一个SWT程序
IBM把投入巨资开发的Eclipse作为一个开源项目捐献给了开源组织Eclipse.org Eclipse出色而有独创的平台特性,现在仍由IBM子公司OTI(主要从事Eclipse开发的人)继续领导着 ...
- 关于SQL语言分类
从功能上划分,SQL语言可以分为DDL,DML和DCL三大类. 事务:可以作用在DML(update.insert.delete)语句上. 1. DDL(Data Definition Languag ...
- JavaScript高级程序设计(第三版)学习笔记13、14章
第13章,事件 事件冒泡 IE的事件叫做事件冒泡:由具体到不具体 <!DOCTYPE html> <html> <head> <title>E ...
- 浅试WebStorm配置Node.js开发环境
web前端开发IDE一直喜欢用WebStorm,这里简单介绍如何用WebStorm搭建一个Node.js开发环境. 首先,需要在本地安装好node.js,以及npm包管理工具.你也可以吧node.js ...
- Java .Net C++ RSA 加密
原文:http://www.codeproject.com/Articles/25487/Cryptographic-Interoperability-Keys DEMO: JAVA .Net C++
- this 函数内部属性
前言:在javascript中我们会经常碰到this,然后this经常出现在function方法里面,有时候可能因为代码很多,无法判断this指向的是谁,其实很简单,一句话总结:谁点出这个this,这 ...
- 通过自关联替代开窗函数实现SQL优化
数据库环境:SQL SERVER 2005 我们平时都是通过开窗析函数来取代自关联,减少表扫描,从而优化SQL.今天,反其道而行, 用自关联改写开窗函数.我们先来看一下SQL. 原SQL语句 SELE ...
- ###Linux基础 - 1
点击查看Evernote原文. #@author: gr #@date: 2014-10-11 #@email: forgerui@gmail.com 前言 为什么学习Linux?:-) 酷Cool ...
- 解决:The Operation couldn't be completed.(LaunchServicesError error 0.)
问题描述:当运行Xcode6时,编译代码成功,但是登陆模拟器失败,显示错误: The Operation couldn't be completed.(LaunchServicesError erro ...
- (转)传统MySQL+ Memcached架构遇到的问题
实际MySQL是适合进行海量数据存储的,通过Memcached将热点数据加载到cache,加速访问,很多公司都曾经使用过这样的架构,但随着业务数据量的不断增加,和访问量的持续增长,我们遇到了很多问题: ...