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

  • SEARCH
  • Home
  • 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 7608545
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T00:56:26+00:00 2026-05-31T00:56:26+00:00

A page displays a banner image which is set to float such that re-sizing

  • 0

A page displays a banner image which is set to float such that re-sizing the page keeps the banner centred.

I want to display some text that will sit upon the banner image at a position relative to the banner’s left bottom corner. The desire is that when the page is re-sized and the banner image moves, so does the text. (The text will change depending upon certain conditions set in the script.)

Experimenting with css, I can get the text over the image, but it does not move when the page is resized. Reading what others have done, I set a div as a placeholder for the image. The text is set within an

and my css position for this selector is set “relative”. I know the css works because I can change the text colour and size, etc. But any css position I set for the text will not change the text float characteristics!

Here’s my code which renders via a php script. Anyone have an idea what’s wrong here?

<!--  html  -->
<div id="wbr_logo" align="center"></div>

<!-- later on down the script.. -->
<?php
function HeaderTitle($cTitle='')
{   
?>
  <div class="wbr_logo" ><H1><?php echo $cTitle;?></H1></div>
<?php
}

<!-- css -->

.wbr_logo {
position:relative;
    height: 200px;
    background-image: url("/ADMIN/images/banner.png"); 
    background-repeat: no-repeat;
    background-position: center;
 }

.wbr_logo H1 {
position:relative;
color:red;
}

The following works nicely (with MANY thanks to DMCS)

<div class="wbr_logo"><h1><div id="floating_text"></div></h1></div>
function HeaderTitle($cTitle='')
{   
    ?>
        <script type="text/javascript">
            $('#floating_text').html("<?php echo $cTitle;?>");
        </script>
    <?php
}
.wbr_logo {
  position: relative;
  width: 1260px;
  height:180px;
  margin: 0 auto; /* centers it */
  background-image: url("/ADMIN/images/wbs_admin_banner.png"); 
}

#floating_text {
  position: absolute;
  left: 2px;
  bottom: 2px;
  color:white;
}
  • 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-31T00:56:27+00:00Added an answer on May 31, 2026 at 12:56 am
    <div class="wbr_logo"><div class="floating_text">Title here</div></div>
    
    
    .wbr_logo {
      position: relative;
      width: imageWidth + 'px';
      margin: 0 auto; /* centers it */
      background-image: url("/ADMIN/images/banner.png"); 
    
    }
    
    .floating_text {
      position: absolute;
      left: 2px;
      bottom: 2px;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a page that displays a list with a of elements with a
I have a page that displays a table in two different modes. In each
i have a page that displays large datasets into html tables. how can i
I have a page that displays search results and has a DOM like the
I have a web page that displays a long line graph inside a div
I have a php page that displays rows from a mysql db as a
We have an HTML page which displays a bunch of pretty bars using divs
I have a web page that displays a list of documents stored on the
I need to display a banner that sticks to the bottom of the browser.
I'm having some trouble getting my page laid out the way I want. I

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.