http://www.tutorialspoint.com/css/css_layouts.htm

css样式大全  时间:2021-01-06  阅读:()
Copyrighttutorialspoint.
comCSS-LAYOUTSCSS-LAYOUTSHopeyouareverycomfortablewithHTMLtablesandyouareefficientindesigningpagelayoutsusingHTMLTables.
ButyouknowCSSalsoprovidesplentyofcontrolsforpositioningelementsinadocument.
SinceCSSisthewaveofthefuture,whynotlearnanduseCSSinsteadoftablesforpagelayoutpurposesThefollowinglistcollectsafewprosandconsofboththetechnologiesMostbrowserssupporttables,whileCSSsupportisbeingslowlyadopted.
Tablesaremoreforgivingwhenthebrowserwindowsizechanges-morphingtheircontentandwrappingtoaccommodatethechangesaccordingly.
CSSpositioningtendstobeexactandfairlyinflexible.
TablesaremucheasiertolearnandmanipulatethanCSSrules.
ButeachoftheseargumentscanbereversedCSSispivotaltothefutureofWebdocumentsandwillbesupportedbymostbrowsers.
CSSismoreexactthantables,allowingyourdocumenttobeviewedasyouintended,regardlessofthebrowserwindow.
Keepingtrackofnestedtablescanbearealpain.
CSSrulestendtobewellorganized,easilyread,andeasilychanged.
Finally,wewouldsuggestyoutousewhichevertechnologymakessensetoyouandusewhatyouknoworwhatpresentsyourdocumentsinthebestway.
CSSalsoprovidestable-layoutpropertytomakeyourtablesloadmuchfaster.
FollowingisanexampleCSStablelayoutcell1CSStablelayoutcell2CSStablelayoutcell3Youwillnoticethebenefitsmoreonlargetables.
WithtraditionalHTML,thebrowserhadtocalculateeverycellbeforefinallyrenderingthetable.
Whenyousetthetable-layoutalgorithmtofixed,however,itonlyneedstolookatthefirstrowbeforerenderingthewholetable.
Itmeansyourtablewillneedtohavefixedcolumnwidthsandrowheights.
SampleColumnLayoutHerearethestepstocreateasimpleColumnLayoutusingCSSSetthemarginandpaddingofthecompletedocumentasfollowsNow,wewilldefineacolumnwithyellowcolorandlater,wewillattachthisruletoa:Uptothispoint,wewillhaveadocumentwithyellowbody,soletusnowdefineanotherdivisioninsidelevel0Now,wewillnestonemoredivisioninsidelevel1,andwewillchangejustbackgroundcolorFinally,wewillusethesametechnique,nestalevel3divisioninsidelevel2togetthevisuallayoutfortherightcolumnCompletethesourcecodeasfollowsbody{margin:9px9px09px;padding:0;background:#FFF;}#level0{background:#FC0;}#level1{margin-left:143px;padding-left:9px;background:#FFF;}#level2{background:#FFF3AC;}#level3{margin-right:143px;padding-right:9px;background:#FFF;}#main{background:#CCC;}FinalContentgoes

TmhHost香港三网CN2 GIA月付45元起,美国CN2 GIA高防VPS季付99元起

TmhHost是一家国内正规公司,具备ISP\ICP等资质,主营国内外云服务器及独立服务器租用业务,目前,商家新上香港三网CN2 GIA线路VPS及国内镇江BGP高防云主机,其中香港三网CN2 GIA线路最低每月45元起;同时对美国洛杉矶CN2 GIA线路高防及普通VPS进行优惠促销,优惠后美国洛杉矶Cera机房CN2 GIA线路高防VPS季付99元起。香港CN2 GIA安畅机房,三网回程CN2 ...

阿里云金秋上云季,云服务器秒杀2C2G5M年付60元起

阿里云(aliyun)在这个月又推出了一个金秋上云季活动,到9月30日前,每天两场秒杀活动,包括轻量应用服务器、云服务器、云数据库、短信包、存储包、CDN流量包等等产品,其中Aliyun轻量云服务器最低60元/年起,还可以99元续费3次!活动针对新用户和没有购买过他们的产品的老用户均可参与,每人限购1件。关于阿里云不用多说了,国内首屈一指的云服务器商家,无论建站还是学习都是相当靠谱的。活动地址:h...

飞讯云E5-2678V3 64GB,湖北十堰100G高防物理机330元/月

飞讯云官网“飞讯云”是湖北飞讯网络有限公司旗下的云计算服务品牌,专注为个人开发者用户、中小型、大型企业用户提供一站式核心网络云端部署服务,促使用户云端部署化简为零,轻松快捷运用云计算。飞讯云是国内为数不多具有ISP/IDC双资质的专业云计算服务商,同时持有系统软件著作权证书、CNNIC地址分配联盟成员证书,通过了ISO27001信息安全管理体系国际认证、ISO9001质量保证体系国际认证。 《中华...

css样式大全为你推荐
海外虚拟主机国内访问速度较快的海外虚拟主机有哪些呀主机租赁租电脑押金多少?虚拟主机价格谁知道租虚拟主机多少钱?域名空间代理免费空间代理,免费域名代理,哪里有?linux虚拟主机怎么样在自己的电脑上安装一个Linux的虚拟机操作系统?已备案域名查询如何快速查询已备案域名并抢注免费vps服务器免费服务器有哪些虚拟空间哪个好虚拟内存设在哪个盘最好虚拟空间免费试用那位给我介绍个可以试用三天的虚拟空间。重庆虚拟空间重庆顺丰快递运的电脑主机19号中午11点到的第二天物流状态还是在重庆集散中心?今天能不能领导件?
广东虚拟主机 vps试用 免费网站空间 虚拟主机是什么 个人注册域名 siteground 美国主机网 linkcloud patcha dropbox网盘 宁波服务器 中国电信测速网 优酷黄金会员账号共享 百度云空间 空间服务器 谷歌搜索打不开 美国asp空间 qq空间打开很慢 wordpress安装 堡垒主机 更多