Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

CSS hanging indent problems

Posted on 2009-04-03
2
973 Views
Last Modified: 2012-05-06
I've written some basic CSS for a list, with a background image.

But the text's hanging indent is off.  I want all the wrapping text to be flush with the text above it...
.moduletableheadbox {
	width: 309px;
}
.moduletableheadbox h3 {
	background-image: url(/images/box/bg_left_small_header.gif);
	height: 31px;
	width: 309px;
	color: #FFF;
	position: relative;
	top: 0px;
	clip: rect(auto,auto,auto,auto);
	margin: 0px;
	padding-top: 0px;
	padding-right: 0px;
	padding-bottom: 0px;
	padding-left: 0px;
	text-indent: 12px;
}
.moduletableheadbox ul.latestnewsheadbox  {
	background-image: url(/images/box/bg_left_small_content.gif);
	color: #FFF;
	list-style-type:disc;
	list-style-position:inside;
	margin-top: 0px;
	margin-right: 0px;
	padding-bottom:15px;
	font-size: 15px;
	text-indent: 15px;
	margin-left:0px;
	padding-left:0px;
}
.moduletableheadbox a.latestnewsheadbox {
	color: #FFF;
}
 
<div class="moduletableheadbox">
  <h3>Recent Features</h3>
  <ul class="latestnewsheadbox">
    <li class="latestnewsheadbox"> <a href="/news/3-newsflash/1603-teaser-one-sheet-for-pulidos-the-graves.html" class="latestnewsheadbox"> Teaser One Sheet For Pulido's 'The Graves'</a> </li>
    <li class="latestnewsheadbox"> <a href="/news/3-newsflash/1604-an-exclusive-look-at-horrorfests-autopsy.html" class="latestnewsheadbox"> An Exclusive Look at Horrorfest's 'Autopsy'</a> </li>
    <li class="latestnewsheadbox"> <a href="/news/3-newsflash/1605-domestic-trailer-and-new-stills-from-sauna.html" class="latestnewsheadbox"> Domestic Trailer and New Stills From 'Sauna'</a> </li>
    <li class="latestnewsheadbox"> <a href="/news/3-newsflash/1606-the-thing-prequel-script-getting-rewritten.html" class="latestnewsheadbox"> 'The Thing' Prequel Script Getting Rewritten!</a> </li>
    <li class="latestnewsheadbox"> <a href="/news/3-newsflash/1607-weird-al-yankovic-the-guest-of-the-newman-hour.html" class="latestnewsheadbox"> Weird Al Yankovic the Guest of The Newman Hour</a> </li>
    <li class="latestnewsheadbox"> <a href="/news/3-newsflash/1608-dino-madness-in-the-land-that-time-forgot.html" class="latestnewsheadbox"> Dino-Madness in 'The Land That Time Forgot'</a> </li>
    <li class="latestnewsheadbox"> <a href="/news/3-newsflash/1609-reminder-horrorhound-weekend-mask-fest-this-weekend.html" class="latestnewsheadbox"> Reminder: HorrorHound Weekend, Mask-Fest THIS Weekend!</a> </li>
    <li class="latestnewsheadbox"> <a href="/news/3-newsflash/1610-canadian-supermodel-cast-in-new-moon.html" class="latestnewsheadbox"> Canadian Supermodel Cast in 'New Moon'</a> </li>
    <li class="latestnewsheadbox"> <a href="/news/3-newsflash/1611-bryan-singer-official-takes-on-the-prisoners.html" class="latestnewsheadbox"> Bryan Singer Official Takes on 'The Prisoners'</a> </li>
    <li class="latestnewsheadbox"> <a href="/news/3-newsflash/1612-tv-full-casting-for-vampire-diaries-pilot.html" class="latestnewsheadbox"> TV: Full Casting For 'Vampire Diaries' Pilot</a> </li>
  </ul>
</div>

Open in new window

csstextindent.jpg
0
Comment
Question by:adworldmedia
2 Comments
 
LVL 11

Expert Comment

by:level9wizard
ID: 24062840
To here:
.moduletableheadbox ul.latestnewsheadbox

add:
list-style: none;

and add:
.moduletableheadbox ul.latestnewsheadbox li
{
    margin: 0;
    padding: 0;
}

0
 
LVL 14

Accepted Solution

by:
amar31282 earned 500 total points
ID: 24063123
try removing this from .moduletableheadbox ul.latestnewsheadbox

        text-indent: 15px;

0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Little bit of help styling my heading 3 31
CSS: How do I override in-line styling 11 25
Css regex 6 38
Html Newline 7 20
This article discusses four methods for overlaying images in a container on a web page
Finding original email is quite difficult due to their duplicates. From this article, you will come to know why multiple duplicates of same emails appear and how to delete duplicate emails from Outlook securely and instantly while vital emails remai…
In this tutorial viewers will learn how to code links for mobile sites that, once clicked, send a call or text to a specified number. For a telephone link (once clicked, calls a number), begin with a normal "<a href=" link tag. For the href, specify…
HTML5 has deprecated a few of the older ways of showing media as well as offering up a new way to create games and animations. Audio, video, and canvas are just a few of the adjustments made between XHTML and HTML5. As we learned in our last micr…

839 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