Solved

Bulleted list carriage return problem

Posted on 2002-05-29
7
264 Views
Last Modified: 2012-05-04
The following code produces an unwanted carriage return (an extra blank line) between the "This is..." line and the first item in the list. How can this be solved?

This is a list:
<ul>
<li>Item #1
<li>Item #2
</ul>

Like this:

This is a list:

     Item #1
     Item #2

This is what I want:

This is a list:
     Item #1
     Item #2

Is there a "style" to control this?
0
Comment
Question by:vogtster
  • 3
  • 3
7 Comments
 
LVL 22

Expert Comment

by:CJ_S
ID: 7041970
By not using ul

This is a list:
<li>Item #1
<li>Item #2
0
 

Author Comment

by:vogtster
ID: 7041995
If I eliminate <ul>, then how do I get an indentation of the list?
0
 
LVL 22

Expert Comment

by:CJ_S
ID: 7042017
for ex.

This is a list:
<table border=0 cellspacing=0 cellpadding=0>
<tr><td width=20>&nbsp;</td><td>
<li>Item #1</li>
<li>Item #2</li>
</td></tr></table>
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 

Author Comment

by:vogtster
ID: 7042035
Yes, I know how to use tables to do formatting, but isn't there a css attribute to control the style of lists and/or indentation?
0
 
LVL 22

Expert Comment

by:CJ_S
ID: 7042040
AFAIk no, but I may very well be wrong.

CJ
0
 
LVL 2

Accepted Solution

by:
Marianne earned 50 total points
ID: 7042041
<ul style="margin-top: 0px;">
<li>Item #1
<li>Item #2
</ul>

Does nothing in NN4.x, but is not harmful and can be used to achieve good results in "good" browsers and acceptable results in "old" ones.
0
 

Author Comment

by:vogtster
ID: 7042058
Thanks, that is what I was looking for and could not figure out from the css documentation.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
Building a website can seem like a daunting task to the uninitiated but it really only requires knowledge of two basic languages: HTML and CSS.
In this tutorial viewers will learn how to embed an audio file in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: : The declaration should display (CODE) HTML5 is supported by the most recent versions of all major browsers…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

919 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now