0

Hi,

I want to display my database records in <ul> <li> format. I have using a free template to design my front end. I am reading database data like this

while ($row = mysql_fetch_assoc($result)) {
    $categoryname = $row['category_name'];
    }

and within the loop i have to display records like this

<li class="odd"><a href="services.html">Processors</a></li>
         <li class="even"><a href="services.html">Motherboards</a></li>
        <li class="odd"><a href="services.html">Processors</a></li>
        <li class="even"><a href="services.html">Motherboards</a></li>
         <li class="odd"><a href="services.html">Desktops</a></li>
        <li class="even"><a href="services.html">Laptops & Notebooks</a></li>
         <li class="odd"><a href="services.html">Processors</a></li>
         <li class="even"><a href="services.html">Motherboards</a></li>
        </ul>

i am not able to display like this. please help me...

1
Contributor
1
Reply
3
Views
5 Years
Discussion Span
Last Post by my3h
This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.