Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6598959
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T18:25:34+00:00 2026-05-25T18:25:34+00:00

How do I create borders from images in CSS/HTML without using CSS3? I have

  • 0

How do I create borders from images in CSS/HTML without using CSS3?

I have three border tiles: left, right, bottom. The should show up (repeat-x/y) to the left, to the right and to the bottom of my content container.

I tried to build div containers around my content container, but I could’nt figure out how to set the properties…

Is this even the best way?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T18:25:34+00:00Added an answer on May 25, 2026 at 6:25 pm

    Use the following HTML structure: ( explanation below )

    <div class="container">
    
        <div class="left"></div>
        <div class="right"></div>
        <div class="bot"></div>
    
    </div>
    

    And the following CSS:

    .container {
        position:   relative;
        padding:    5px; // size of your border images
    }
    
    .container .left {
        position:   absolute;
        left:       0;
        top:        0;
        background: url(border_left.jpg) repeat-y;
        width:      5px;
        height:     100%;
    }
    
    .container .right {
        position:   absolute;
        right:      0;
        top:        0;
        background: url(border_right.jpg) repeat-y;
        width:      5px;
        height:     100%;
    }
    
    .container .bot {
        position:   absolute;
        left:       0;
        bottom:     0;
        background: url(border_bot.jpg) repeat-x;
        width:      100%;
        height:     5px;
    }
    

    Basically what you do here is the following:

    1. You create a container which is relatively positioned so absolutely positioned elements inside it will be positioned within its boundaries. It also has a padding equal to (could also be higher than) the width / height of the border images to make up for the room they take up.
    2. You add three divs inside of the container that get pushed to the left, right and bottom of the container and stretch along the entire width / height.

    This jsFiddle illustrates what I’m explaining here, using background colors instead of images.

    You can see the borders overlap at the corners, you could fix this by also creating extra images that are positioned in the corners.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to create a dialog with a title, borders (left, right, bottom) as
I have the following page http://valogiannis.com/freelancer/ecommerce-final/ In the right there are three images and
I'm looking for the best way to create a custom border around an HTML
I need to create control to draw border around its child. So, I have
I want to create a html table with a 1pt black outer border and
I am trying to create a css menu. I would like to remove border
I have been trying to create a HTML E-mail, which is just one image
Im trying to create some chart images without ever displaying those charts on the
I have created an HTML page which uses simple CSS (no javascript) for menu
I have two divs, one on the left, and one on the right side

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.