課程
/前端開(kāi)發(fā)
/HTML/CSS
/企業(yè)網(wǎng)站綜合布局實(shí)戰(zhàn)
hello world!
為什么紅線不出來(lái)呢,是不是哪里錯(cuò)了,求高手指點(diǎn)
2015-05-28
源自:企業(yè)網(wǎng)站綜合布局實(shí)戰(zhàn) 2-3
正在回答
你看看你的分號(hào)有沒(méi)有在中文狀態(tài)下輸入
盒子距頁(yè)面有10px的上邊距---margin-top:10px,盒子中的內(nèi)容距左側(cè)有15px填充---padding-left:15px
<style type="text/css">.myBox{width:200px;height:100px;border:1px solid red;margin-top:10px;padding-left:15px;}</style>
<style type="text/css">
.myBox{
????????width:200px;
????????height:100px;
????????border:1px?solid?red;
????????padding-top:10px;
????????padding-left:15px;
????????}
</style>
<!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"?/> <title>盒子模型練習(xí)題</title> <!--在此定義一個(gè)類選擇器myBox,根據(jù)要求設(shè)置相關(guān)CSS屬性--> <style> ????.myBox{ ????????width:200px; ????????height:100px; ????????border:1px?solid?red; ????????padding-top:10px; ????????padding-left:15px; ????????} </style> </head> <body> <div?class="myBox">Hello?World!</div> <!--在此添加一個(gè)div標(biāo)簽,并設(shè)置其class屬性為myBox--> </body> </html>
舉報(bào)
本課程重點(diǎn)介紹HTML/CSS實(shí)現(xiàn)常見(jiàn)企業(yè)網(wǎng)站布局的方法
2 回答盒子模型的概念
1 回答盒子模型中的(左)填充是啥?
5 回答盒子寬度和高度問(wèn)題
1 回答盒子的寬度和高度
2 回答請(qǐng)問(wèn)news course sidebar 三個(gè)盒子高度為什么不一致,course盒子低了一點(diǎn)
Copyright ? 2025 imooc.com All Rights Reserved | 京ICP備12003892號(hào)-11 京公網(wǎng)安備11010802030151號(hào)
購(gòu)課補(bǔ)貼聯(lián)系客服咨詢優(yōu)惠詳情
慕課網(wǎng)APP您的移動(dòng)學(xué)習(xí)伙伴
掃描二維碼關(guān)注慕課網(wǎng)微信公眾號(hào)
2016-08-20
你看看你的分號(hào)有沒(méi)有在中文狀態(tài)下輸入
2015-05-31
盒子距頁(yè)面有10px的上邊距---margin-top:10px,盒子中的內(nèi)容距左側(cè)有15px填充---padding-left:15px
2015-05-31
<style type="text/css">
.myBox{
width:200px;
height:100px;
border:1px solid red;
margin-top:10px;
padding-left:15px;
}
</style>
2015-05-29
<style type="text/css">
.myBox{
????????width:200px;
????????height:100px;
????????border:1px?solid?red;
????????padding-top:10px;
????????padding-left:15px;
????????}
</style>
2015-05-28