猿问

怎么传人数据框没办法居中啊?是要用绝对定位吗?

<!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">

<style type="text/css">

body{margin:0; padding:0;}

#top{height:30px; background:#CCC;}

#mainbody{width:550px; height:300px; margin:0 auto}

#soso{height:20px; width:90px; margin: o auto;}

#findbody{width:75px;height:50px;margin:0 auto} 

</style>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>百度一下,你就知道</title>

</head>


<body>

<div class="type">

<div id="top">郑州:晴转多云</div>

    <div id="mainbody"> <img src="bd_logo1_31bdc765.png"alt="bd_logo1_31bdc765.png"title="百度"/></div>

    <div id="soso">

    <form method="post" action="save.php">

    <input type="text" name="myName"/></form>

     <input type="submit" value="提交" name="submitBtn" />

    </div>

    <div id="findbody"><a href="https://www.baidu.com/"title="进入百度">设为首页</a>

   

    </div>

</div>


</body>

</html>

_Jack_lei
浏览 1414回答 1
1回答

侠客岛的含笑

你没设置居中啊
随时随地看视频慕课网APP
我要回答