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 3420800
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T06:02:53+00:00 2026-05-18T06:02:53+00:00

Firstly, I would like to show you a image(made in paint). Okay current is

  • 0

Firstly, I would like to show you a image(made in paint).

alt text

Okay “current” is what I have now. I want to place a box over the image to the right, with black background, and then have text inside this box.

I tried myself using z-index and so, but without any success. Here’s what I tried:

<div> <!-- start div for image -->
  <img style="z-index: -1;" src="1.jpg" width="860" height="240"> <!-- the image -->
</div> <!-- end div -->
<div style="z-index: 1; width: 300px; background: #000; position: relative;">
  <div style="margin: auto;">
    text text text
  </div>
</div>

but this didnt turn out any good. How can i do this?

  • 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-18T06:02:53+00:00Added an answer on May 18, 2026 at 6:02 am

    Something like this?

    http://jsfiddle.net/QGMPB/1/

    HTML:

    <div id="wrap">
        <img src="http://jsfiddle.net/img/logo.png" />
        <div id="text">text</div>
    </div>
    

    CSS

    #wrap {
        position:relative; /* make this relative to have the inner div absolute without     breaking out */
        width: 200px;  /* fix the width or else it'll be the entire page's width */
        background: silver; 
        border: 1px solid grey
    }
    
    #text {
        position: absolute; 
        width: 40px; 
        right: 0; 
        top: 0; 
        bottom: 0; 
        background: black; 
        color:white
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Firstly, I would like to say that I have tested if my link to
What I want: I would like to have a ScrollView in my Silverlight 4
Firstly I would like confirmation that I have understood NSCopying correctly ... In order
Firstly, I do not have any malicious intent out of this question. I would
Firstly I would like to say that I am quite new to Spring (in
Firstly I would just like to thank everyone for reading this and answering my
I have a huge CSV file I would like to process using Hadoop MapReduce
Firstly, I would like to say that I don't mean the full path, what
The scenario is I would like to insert an record like this: Firstly, i
I am new to testing field. I would like to firstly ask in what

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.