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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T07:19:31+00:00 2026-05-12T07:19:31+00:00

I am creating a page that uses AJAX to switch content, and each of

  • 0

I am creating a page that uses AJAX to switch content, and each of the 5 pages have their own background colour.

Changing the page, makes the current background animate to the new one. I have 24bit PNGs with alpha transparency which overlay the background colours changing (it works alright).

There is however, one small problem. On occasion, in Firefox 3.5.1 at least, and Safari 3/4, the background will change, however my #main-container div will not. The container has background: transparent to be sure.

The problem is, this doesn’t occur everytime, only sometimes. Could this just be a quirk of what I’m making the browser do?

I am using a jQuery plugin to animate the background colour.

I was wondering, does anyone know how I could force the #main-container to inherit it’s parent container’s (body) background?

I know I could ping it with a setInterval(), but that will be an ugly solution.

Any suggestions very appreciated.

The site is viewable @ http://www.acura.com.au/~kohana/

There is a menu to the right, and clicking those sections are where the problem is. You may have to navigate at least 8 times or so to see the quirk.

Any help is very much appreciated!

UPDATE

I’m going to attempt a setInterval() to check the colours… but not sure what exactly I’ll do if I detect them being wrong.

  • 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-12T07:19:31+00:00Added an answer on May 12, 2026 at 7:19 am

    To follow on from my above comment with respect to timing (sorry this isn’t an actual answer, but there’s not enough room in the comment field)… I think the problem is due to the timing of the following two events:

    1. The dynamic (async) load of the new stylesheet
    2. The updatePage function where you grab the background colour to fade to

    The problem (if i’m reading your code right) is that you’re grabbing the colour to fade to from a div which is styled by the style sheet that you’re dynamically loading. If it hasn’t finished loading (not just the downloading, but the application of styles to the DOM), then the background colour you grab will be the old one.

    So steps to take from here… firstly try changing the timeout on your CSS loader to be really small & see if that makes the bug appear more often (or make it larger & see if it goes away). If this seems to match up, then a possible solution is to use a timeout in a loop that testing the background colour against the known old colour until you see it change & then carry on with your background animation, etc.

    Hope that helps…

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

Sidebar

Related Questions

I have an object oriented framework that uses a page design, where each page
I'm creating an asp.net page that uses the google map api. The page loads
I have a document that my asp.net page is creating and I need to
I'm creating a WP theme that will have two sections midway down the page.
I am creating a GridView/DetailsView page. I have a grid that displays a bunch
I have simple AJAX function that uses jQuery to return an array of 300
I have a complex page that uses knockout to render the contents via templates.
I have report page that uses dynamic xtrachart s. To dynamically create the xtrachart
I have a table which uses a background image that is 1500px wide. Since
I'm creating a page that uses Linqfor data access and I'm using DataList to

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.