Tip: You can modify some of the code before running
<! DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 transitional//en" "Http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd "><br/> <ptml xmlns=" http://www.w3.org/1999/xhtml "><br/> <pead><br/> <meta http-equiv= "Content-type" content= "text/html; Charset=utf-8 "/></p> <style type=" Text/css "> miao{width:170px;height:100px;display:table; Text-align:center;border:solid 1px red; . Miao span{display:table-cell;vertical-align:middle;border:solid 1px blue; Miao span img{border:dashed 1px green; </style> <p><!--[if LTE IE 7]></p> <style type= "Text/css" > Miao{position:relative;o Verflow:hidden;} . Miao span{position:absolute;left:50%;top:50%; Miao span img{position:relative;left:-50%;top:-50%;} </style > <p><! [endif]--><br/> </pead><br/> <body></p> <p> Fixed high-width container, picture vertical board. The </p> <p> green container is span to align its upper-left corner with the container's center point. Red is a specific picture, set the negative again so that their center point and the center of the parent container overlap, and eventually reached the vertical bureauThe purpose. </p> <div class= "Miao" > <span></span> </div> <pr/> <div class= "Miao" > <s pan></span> </div> <pr/> <div class= "Miao" > <span></span> </div> <P&G t;</body><br/> </ptml></td> </tr> </table>
Tip: You can modify some of the code before running