Posts

Showing posts with the label center

How to align a to the middle (horizontally/width) of the page

How to align a <div> to the middle (horizontally/width) of the page I have a div tag with width set to 800px . When the browser width is greater than 800px , it shouldn't stretch the div but it should bring it to the middle of the page. div width div 26 Answers 26 <body> <div style="width:800px; margin:0 auto;"> centered content </div> </body> This is correct for demo purposes, but obviously not using inline styles in the final markup – gonzohunter Jun 5 '09 at 10:36 Just make sure to apply 'text-align: center' to the <body> or else IE6 will not center the div. Then add text-align: left; to your div. – avdgaag J...

Do not want the text to be centered

Image
Do not want the text to be centered i've never programmed before or anything, but i have a college project in which i have to edit a layout. there's a part of it in which the text is kinda in center, when it reaches the center of the page it skippes to next line.. i want it to continue normally.. https://jsfiddle.net/nqpa6jh0/#&togetherjs=vORwosTiHV .image.feature2 { display: block; margin: 0 0 0em 0; } .image.feature2 img { display: block; width: 100%; border-radius: 50%; width: 200px; height: 200px; float: left } .image.feature3 img { display: block; width: 100%; border-radius: 50%; width: 200px; height: 200px; float: right; <div class="wrapper style2"> <section class="container"> <header class="major"> <h2>Depoimentos</h2> <span class="byline">Os viajantes recomendam.</span> </header> <div class="row no-collapse-1">...