Results 1 to 4 of 4

Thread: Horizontal center layout in CSS

  1. #1
    Join Date
    Apr 2009
    Posts
    79

    Horizontal center layout in CSS

    What is the html code to create Horizontal center layout in CSS and what is the syntax to declare center. I want to display some text in center on html page.

  2. #2
    Join Date
    May 2008
    Posts
    2,297

    Re: Horizontal center layout in CSS

    The <center> tag is used to center text in html . The <center> tag is supported in all major browsers. However, it is deprecated and should be avoided! CENTER is defined as equivalent to DIV with ALIGN=CENTER. CENTER was introduced by Netscape before they added support for the DIV element. Example : Center text in an HTML page : <center> Text will be display in center</center>

  3. #3
    Join Date
    Jan 2009
    Posts
    199

    Re: Horizontal center layout in CSS

    <CENTER ...> it display the text in center <CENTER ...> is exactly equivalent to the text which is display <DIV ALIGN=CENTER>. <CENTER ...> to display text Use <DIV ALIGN=CENTER> instead. <DIV ALIGN=CENTER> HTML center tag </DIV>

  4. #4
    Join Date
    Dec 2008
    Posts
    177

    Re: Horizontal center layout in CSS

    Code:
    <P> (breakes line)
    This is a normal paragraph which usually means left alignment and the next text display in next line.
    </P>
    <CENTER>
    <P>
    This is text which will be centered.
    </P>
    <P>
    This is a longer text paragraph which will be centered.The center element was deprecated in HTML 4.01,It is so long that line breaks will most probably occur.
    </P>
    </CENTER>

Similar Threads

  1. Replies: 3
    Last Post: 31-07-2013, 11:26 AM
  2. How to place PS3, Vertical or Horizontal
    By Izna in forum Portable Devices
    Replies: 5
    Last Post: 10-06-2011, 10:31 AM
  3. Horizontal black lines on my DLP TV
    By Marjorie in forum Portable Devices
    Replies: 5
    Last Post: 28-09-2010, 06:41 AM
  4. How to create horizontal menu using CSS
    By Efigenio in forum Software Development
    Replies: 6
    Last Post: 29-03-2010, 08:40 PM
  5. Horizontal Scrolling Div in CSS
    By Zoe in forum Software Development
    Replies: 3
    Last Post: 02-07-2009, 11:55 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Page generated in 1,713,889,546.75140 seconds with 16 queries