The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS How to put images in unordered list

  • This topic is empty.
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
  • #165200

    Hi all,i am new member and newbie at web design. I want to code this
    but i don’t know how,all day i search at google and i didn’t find answer.
    I wrote this in my css
    #one img {width: 26px;height: 26px;}
    .a{list-style-image: url(1.png);}
    .b{list-style-image: url(2.png);}
    .v{list-style-image: url(3.png);}
    .g{list-style-image: url(4.png);}
    .d{list-style-image: url(5.png);}
    .e{list-style-image: url(6.png);}
    .z{list-style-image: url(7.png);}

    and in HTML

    <b style=”margin-left:50px”>A Pre-Listing Inspection will:</b>

      <li class=”a”>Help your home sell faster.
      <li class=”b”>Help your home sell for more.
      <li class=”v”>Tell buyers your confident in the in the condition of your home.
      <li class=”g”>Prevent unexpected issues from deraling a closing.
      <li class=”d”>Preempt post-sale buyer inspection surprises.
      <li class=”e”>Show critical repairs prior to the buyer learning first time.
      <li class=”z”>Identify normal wear and tear and calm a buyer’s anxiety

    and got this

    Do i need to make so much class?


    For modern browsers you can use pseudo class selectors like nth-of-type or nth-child
    When you want more control over spacing, then you can use background-images on the list-items, instead of list-style-image.

    (Initial reaction got stuck in the filter – probably because of too many links).


    And how to change the image size? where to type and what?
    i tryed
    .a img{width=”100px”} and that didnt work


    thank you :)

Viewing 5 posts - 1 through 5 (of 5 total)
  • The forum ‘CSS’ is closed to new topics and replies.