SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    Git-R-Done
    Join Date
    Nov 2001
    Posts
    1,194
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Is it possible to use an image for a border?

    I have a UL tag and I need to apply an image to the right side of the last LI. Is there anyway that I can accomplish this by using an image for border-right? If so, how?
    John Saunders

  2. #2
    ☆★☆★ silver trophy vgarcia's Avatar
    Join Date
    Jan 2002
    Location
    in transition
    Posts
    21,235
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)
    border-image is a CSS3 property, and one that unfortunately isn't available in browsers yet . However, you might have luck with positioning the background image to the right, like so:
    Code:
    li.last {
      background-image: url(arrow.gif);
      background-repeat: no-repeat;
      background-position: right;
    }
    HTML Code:
    <ul>
    <li>Entry number one.</li>
    <li>Entry number two.</li>
    <li class="last">Last entry.</li>
    </ul>

  3. #3
    Git-R-Done
    Join Date
    Nov 2001
    Posts
    1,194
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks! I ended up getting it to work by applying padding-right to the UL tag and using code similar to what you posted.
    John Saunders


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •