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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T12:03:13+00:00 2026-06-10T12:03:13+00:00

Can you guys help me in tweaking out my loading bar css and/or html.

  • 0

Can you guys help me in tweaking out my loading bar css and/or html. I’ve got two problems existing right now with my current loading bar.

One is that there is some excess shadow going out of the bar in the left and right outside the border (which makes it look like the border-radius is pixelated when zoomed properly). I know it’s the box-shadow‘s problem cause it’s not there when I remove the box shadow property for both #progress and #buffer.

excess shadow screenshot

And another is quite minor but is really bugging me. When the progress/buffer bar is just starting to load (change style="width:0.4%"), the form of the div with radius goes outside the container:

div goes outside container

I know I can overflow:hidden it (which I already do in the #loading_bar_container), but I think position:absolute doesn’t want to get hidden (which I need absolute cause I need the two bars to be in one position, overlapping each other). When I remove though the #buffer (so there’s only one bar), and remove loading_bar‘s position:relative and #progress ‘s position:absolute, I get the scenario I want which is:

enter image description here

I’ll add here a jsfiddle fragment of the code so we can play with it.

Cheers!

PS: I think tag should be loading-bar but I can’t create a new tag so I add it as progress-bar.

Edit: I’ve done this test in Chrome and @Oriol mentioned it works well in FF. I’ve checked and FF does display it the way I wanted it to. I’ve checked with Safari and it displays the same was as Chrome. So this question is for Chrome and Safari so far. Haven’t checked it with IE (scared).

  • 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-06-10T12:03:14+00:00Added an answer on June 10, 2026 at 12:03 pm

    It seems it’s a Chrome’s bug caused by position:relative.

    Compare http://jsfiddle.net/VeJNt/2/ with http://jsfiddle.net/VeJNt/3/

    Then you can use

    #progress {
        margin-top:-8px;
    }​
    

    instead of those position:relative and position:absolute.

    See it here: http://jsfiddle.net/VeJNt/4/

    But why do you have both loading_bar_container and loading_bar?

    I think you should simplify your code: http://jsfiddle.net/VeJNt/5/

    Edit:

    If you want a more general code, which doesn’t depend on the number of bars, you can use

    #loading_bar>div {
      border-radius:7px;
      height:100%;
      width:0%;
      margin-top:-8px;
    }
    #loading_bar>div:first-child {
      margin-top:0;
    }
    

    And then you only have to set the background and box-shadow to each bar.

    See it here: http://jsfiddle.net/VeJNt/6/

    It isn’t cumulative (-8px to the second bar, -16px to the third one, …) because when you set a margin it isn’t like if you are setting position:relative and setting top to -8px, -16px…

    If you set margin-top:10px to an element, it goes 10px down, but doesn’t overlap the next element (all the following elements go 10px down too).

    Then, if you set margin-top:-8px to the second bar, it goes 8px up, but it doesn’t appear any space between it and the next bar (all the following bars go 8px up too).
    Then, you don’t have to set margin-top:-16px to the third bar, you only need -8px, because it has gone up 8px already because of the second bar.

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

Sidebar

Related Questions

I'm learning Ruby right now and I got stuck, maybe you guys can help
Can you guys help me out with this? I've got a form and it
Can you guys help me figure this out? I have the following JavaScript snippet:
I'm hoping you guys can help me figure out why this is happening. I've
First time stackoverflow user but occasional lurker, hope you guys can help me out.
can you guys help to convert a JPG File into an 2-dimensional int []
Maybe you guys can help: I have a variable called $bio with bio data.
I hope some of you guys can help me with this problem.... I have
I'm really confused so I hope you guys can help me. I know how
I've run in to a problem I hope you guys can help me with.

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.