SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Enthusiast
    Join Date
    May 2010
    Posts
    84
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    simple fadein jumpy problem (flashes content before fadein) in safari

    my site

    http://hahaclothiers.com/store/index...e=products_all


    the fadein javascript flashes the hidden caontent beofre fading in.......sometimes(you might have to click a couple of the left hand links (shirts, pants, etc to see the flash i am talking about)

    i put a overscroll-y:scroll on the html because i thought the problem was the interaction of the script with the page resizing when cyclingthrough links........this did not really help


    it works great in firefox

    below is the code

    <script type="text/javascript" src="http://code.jquery.com/jquery-1.5.min.js"></script>

    <script type="text/javascript">
    $(document).ready(function(){

    $(document).ready(function () {
    $('.centerColumn').fadeIn(1700);
    });

    });

    </script>

    <script type="text/javascript">
    $(document).ready(function(){

    $(document).ready(function () {
    $('.centeredContent').fadeIn(1700);
    });

    });
    </script>

    thanks!!

  2. #2
    Unobtrusively zen silver trophybronze trophy
    paul_wilkins's Avatar
    Join Date
    Jan 2007
    Location
    Christchurch, New Zealand
    Posts
    14,526
    Mentioned
    83 Post(s)
    Tagged
    4 Thread(s)
    Quote Originally Posted by phillycheese123 View Post
    http://hahaclothiers.com/store/index...e=products_all

    the fadein javascript flashes the hidden caontent beofre fading in.......sometimes(you might have to click a couple of the left hand links (shirts, pants, etc to see the flash i am talking about)
    What I'm seeing when I click on shirts or pants, is that a new page is being navigated to, resulting in a whole new reload of the content.
    Programming Group Advisor
    Reference: JavaScript, Quirksmode Validate: HTML Validation, JSLint
    Car is to Carpet as Java is to JavaScript

  3. #3
    SitePoint Enthusiast
    Join Date
    May 2010
    Posts
    84
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    ...im uzing zencart....their all_products page is a convenient way of having all my products listed automatically. the 3 below...shirts,pants,jackets are diffent paths on the same page.

    did you see the flash im talking about...the content showing then dissapearing then fading in when it should not show itself before the fadein. its only in safari (ive only tested safari and firefox) and it seems to happen its also sporatically

    i feel like you know damn well what your talking about but i cant grasp it .....

    the reason i say this is when you click on one of the listings under the l categories(shirts pantsjackets) the method for displaying different content is through a Products_id rather than the path that is used to cycle through different categories.

    categories uses paths...this means its on different pages?

    product image uses product ids.... so this means its on the same page? the main product image(where it gives either sold out or shopping cart option on right side) does not have this problem....so you are saying because its using ids and therefore on the same page it doesnt have this issue...? i thought that the fadein on doc ready would apply to all content that is being loaded.

    i apoligize if im a bit confusing. thanks for the help

  4. #4
    SitePoint Enthusiast
    Join Date
    May 2010
    Posts
    84
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    sorry a couple beers had me rambling last night i didnt make much sense. maybe ill do a tad better.....

    1st

    There seems to be no prob with the fadein script when clicking through the images on http://hahaclothiers.com/store/index...&products_id=8


    but all of the other pages have the flash before fadein problem....at seemingly random times(you might have to keep clicking different links to see the flash im talking about) so if this issue is due to a new page being navigated to what can i add to the fadein code to prevent this? do all the fadeins that are attached to completely new page loads need something other than document ready{ ?

    why does this code suffice for firefox but not safari?

    i hope ive been a bit more clear

    thankyou

  5. #5
    Unobtrusively zen silver trophybronze trophy
    paul_wilkins's Avatar
    Join Date
    Jan 2007
    Location
    Christchurch, New Zealand
    Posts
    14,526
    Mentioned
    83 Post(s)
    Tagged
    4 Thread(s)
    Quote Originally Posted by phillycheese123 View Post
    but all of the other pages have the flash before fadein problem....at seemingly random times(you might have to keep clicking different links to see the flash im talking about) so if this issue is due to a new page being navigated to what can i add to the fadein code to prevent this?
    It is not the fadein that is responsible for the flash, where everything on the page goes away then comes back.

    When a new page is navigated to, the old page goes away and a new page is created. Some web browsers do that smoother and faster than others.
    Programming Group Advisor
    Reference: JavaScript, Quirksmode Validate: HTML Validation, JSLint
    Car is to Carpet as Java is to JavaScript


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •