{"id":208,"date":"2009-05-16T22:51:14","date_gmt":"2009-05-17T03:51:14","guid":{"rendered":"http:\/\/jaewon.hwang.info\/jaewon\/?p=208"},"modified":"2010-07-06T19:22:46","modified_gmt":"2010-07-06T23:22:46","slug":"how-to-align-a-div-box-at-the-center-using-css","status":"publish","type":"post","link":"https:\/\/jaewon.hwang.info\/jaewon\/2009\/05\/how-to-align-a-div-box-at-the-center-using-css\/","title":{"rendered":"How to align a DIV box at the center using CSS"},"content":{"rendered":"<p>Here are some examples of how the new web standard of CSS deals with horizontal positioning.<\/p>\n<p style=\"margin: 0pt;\">&lt;div style=&#8221;text-align: center;&#8221;&gt;test&lt;\/div&gt;<\/p>\n<div style=\"border: 1px solid #000000; text-align: center;\">test<\/div>\n<p style=\"margin: 20px 0pt 0pt;\">&lt;div style=&#8221;text-align: center; width: 200px;&#8221;&gt;test&lt;\/div&gt;<\/p>\n<div style=\"border: 1px solid #000000; width: 200px; text-align: center;\">test<\/div>\n<p style=\"margin: 20px 0pt 0pt;\">&lt;div style=&#8221;text-align: center; width: 400px;&#8221;&gt;&lt;div style=&#8221;width: 200px;&#8221;&gt;test&lt;\/div&gt;&lt;\/div&gt;<\/p>\n<div style=\"border: 1px solid #000000; width: 400px; text-align: center;\">\n<div style=\"border: 1px solid #000000; width: 200px;\">test<\/div>\n<\/div>\n<p style=\"margin: 20px 0pt 0pt;\">&lt;div style=&#8221;margin-left: auto; margin-right: auto;&#8221;&gt;test&lt;\/div&gt;<\/p>\n<div style=\"border: 1px solid #000000; margin-left: auto; margin-right: auto;\">test<\/div>\n<p style=\"margin: 20px 0pt 0pt;\">&lt;div style=&#8221;margin-left: auto; margin-right: auto; width: 200px;&#8221;&gt;test&lt;\/div&gt;<\/p>\n<div style=\"border: 1px solid #000000; width: 200px; margin-left: auto; margin-right: auto;\">test<\/div>\n<p style=\"margin: 20px 0pt 0pt;\">&lt;div style=&#8221;width: 400px;&#8221;&gt;&lt;div style=&#8221;margin-left: auto; margin-right: auto; width: 200px;&#8221;&gt;test&lt;\/div&gt;&lt;\/div&gt;<\/p>\n<div style=\"border: 1px solid #000000; width: 400px;\">\n<div style=\"border: 1px solid #000000; width: 200px; margin-left: auto; margin-right: auto;\">test<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Here are some examples of how the new web standard of CSS deals with horizontal positioning. &lt;div style=&#8221;text-align: center;&#8221;&gt;test&lt;\/div&gt; test &lt;div style=&#8221;text-align: center; width: 200px;&#8221;&gt;test&lt;\/div&gt; test &lt;div style=&#8221;text-align: center; width: 400px;&#8221;&gt;&lt;div style=&#8221;width: 200px;&#8221;&gt;test&lt;\/div&gt;&lt;\/div&gt; test &lt;div style=&#8221;margin-left: auto; margin-right: auto;&#8221;&gt;test&lt;\/div&gt; test &lt;div style=&#8221;margin-left: auto; margin-right: auto; width: 200px;&#8221;&gt;test&lt;\/div&gt; test &lt;div style=&#8221;width: 400px;&#8221;&gt;&lt;div style=&#8221;margin-left: auto; margin-right: auto; [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[16],"tags":[31,70],"class_list":["post-208","post","type-post","status-publish","format-standard","hentry","category-computer","tag-css","tag-html"],"_links":{"self":[{"href":"https:\/\/jaewon.hwang.info\/jaewon\/wp-json\/wp\/v2\/posts\/208","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/jaewon.hwang.info\/jaewon\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jaewon.hwang.info\/jaewon\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jaewon.hwang.info\/jaewon\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/jaewon.hwang.info\/jaewon\/wp-json\/wp\/v2\/comments?post=208"}],"version-history":[{"count":0,"href":"https:\/\/jaewon.hwang.info\/jaewon\/wp-json\/wp\/v2\/posts\/208\/revisions"}],"wp:attachment":[{"href":"https:\/\/jaewon.hwang.info\/jaewon\/wp-json\/wp\/v2\/media?parent=208"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jaewon.hwang.info\/jaewon\/wp-json\/wp\/v2\/categories?post=208"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jaewon.hwang.info\/jaewon\/wp-json\/wp\/v2\/tags?post=208"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}