0

I'm new to all this. I've got a template for a mock website I'm working on. The left menu was fine in the template. Since I've changed the left menu to appear in PHP it keeps indenting to the left. I've tried changing the css to have margin-left = 0px and other things But it remains the same. You can see that padding has 30px left but I changed that to 0px and still remained indented and the ticks were over the text.

indent http://i.minus.com/iwFNaTVEdSzZw.png

CSS

ul.left_menu{
width:196px;
padding:0px;
margin:0px;
list-style:none;
}
ul.left_menu li{
margin:0px;
list-style:none;
}
ul.left_menu li.odd a{
width:166px;
height:25px;
display:block;
background:url(images/checked.png) no-repeat left #dad0d0;
background-position:5px 5px;
border-bottom:1px #FFFFFF solid;
text-decoration:none;
color:#504b4b;
padding:0 0 0 30px;
line-height:25px
 } ;

xHTML

<div class="left_content">
  <div class="title_box">Categories</div>
  <ul class="left_menu">
    <li class="odd">
  <?php  include("category_menu.php"); ?>
    </li>

Edit

//take the book types to be used on the left menu (leftColumn.php)
$query_category_menu = "SELECT category_id, category_name FROM      computineerCategory";

$query_category_menu_result = mysql_query($query_category_menu)
 or die(mysql_error());

echo '<ul>';
while($type_category_data = mysql_fetch_array($query_category_menu_result))
{
    print "<a href = 'category.php?categoryid=".$type_category_data["category_id"]."'>".$type_category_data["category_name"]."</a>";
}
echo '</ul>';
?>
1
  • 1
    can you post whats inside category_menu.php? I'd imagine you've output an extra <ul> in there, but can't say for certain. Commented Apr 19, 2012 at 15:24

1 Answer 1

2

Take out the

echo '<ul>'

echo '</ul>'

from the category_menu file you don't need to add these twice

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.