如何让网页顶格显示? 只需要在css中添加一个有关body的样式 body{ margin: 0 0 0 0; } top right bottom left 都设置为 0,上右下左 本质上 让body标签的边距为0,不设置的话,会有个默认的边距