HTML CSS Tip: Horizontal List - UL LI tags

 

To make an HTML list appear horizontally instead of stacked vertically, simpy set the list item tag's display style to "inline" in your CSS file or style attribute, and be sure your container element's width is wide enough for the list items to be stacked horizontally.

example:

.exHorizontalListClass {

  /* Horizontal List Items: */ 
  display: inline;

  /* To remove bullets: */
  list-style: none;

}

 

No comments (Add your own)

Add a New Comment

Enter the code you see below:
code
 

Comment Guidelines: No HTML is allowed. Off-topic or inappropriate comments will be edited or deleted. Thanks.