Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    New Coder
    Join Date
    Oct 2011
    Posts
    65
    Thanks
    1
    Thanked 0 Times in 0 Posts

    [MooTools] Bug in ie 6, 7 and 8

    I am using a slideshow, I dont know javascript however do understand something, and been researching trying to find a bug (a hack) as the slideshow have a loading image that shows up while the images load.
    Its works perfect in firefox, chrome, safari and ie 9, however in ie6, 7 and 8 the loading image only shows up on the first image, if you go to next image there are no loading image, its only blank.
    It uses the mootols library, and I have the version without loading image and the version with loading image, so I pass the code here which as per me is what its about the loading image, if somebody knows of a known bug in ie6, ie7 and ie8. There are many using ie8 so this is important to me, thanks.
    I know there must be more code that have to do with the loader image, however maybe the bug is here.
    Any help would be appreciated. Thanks in advance.
    Code:
    loadedPictures : {},
    loaderGif : 'images/ajax-loader.gif',
    
    initialize : function(config) {
    if(config.listeners) {
    this.addEvents( config.listeners);
    }
    
    if(config.preload !== undefined){
    this.preload = config.preload;
    if(config.loaderGif !== undefined){
    this.loaderGif = config.loaderGif;
    }
    }
    if(config.autoplay !== undefined) {
    if (config.autoplay.enabled !== undefined) {
    this.autoplay.enabled = config.autoplay.enabled;
    }
    if(config.autoplay.pause){
    this.autoplay.pause = config.autoplay.pause;
    }
    if(config.autoplay.buttons) {
    if(config.autoplay.buttons.start){
    if(config.autoplay.buttons.start.txt){
    this.autoplay.buttons.start.txt = config.autoplay.buttons.start.txt;
    }
    if(config.autoplay.buttons.start.enabled !== undefined){
    this.autoplay.buttons.start.enabled = config.autoplay.buttons.start.enabled;
    }
    if(config.autoplay.buttons.stop.txt){
    this.autoplay.buttons.stop.txt = config.autoplay.buttons.stop.txt;
    }
    if(config.autoplay.buttons.stop.enabled !== undefined){
    this.autoplay.buttons.stop.enabled = config.autoplay.buttons.stop.enabled;
    }
    }
    
    }
    }
    More:
    getLargeImagePath : function(id) {
    if(!this.loadedPictures[id] && this.loaderGif){
    this.dom.loaderImages = this.dom.loaderImages || {};
    var loader = this.dom.loaderImages[id] = new Element('img');
    loader.addEvent('load', function(){
    this.setStyles({
    width: this.getSize().x,
    height : this.getSize().y,
    'margin-left' : this.getSize().x /2 * -1,
    'margin-top' : this.getSize().y /2 * -1
    })
    });
    loader.setStyles({
    position : 'absolute',
    left : '50%',
    top : '50%',
    'margin-left': '-110px',
    'margin-top': '-10px'
    });
    loader.setProperty('src', this.loaderGif);
    Last edited by Kor; 11-09-2011 at 02:12 PM. Reason: set the MooTools prefix

  • #2
    Kor
    Kor is offline
    Red Devil Mod Kor's Avatar
    Join Date
    Apr 2003
    Location
    Bucharest, ROMANIA
    Posts
    8,478
    Thanks
    58
    Thanked 379 Times in 375 Posts
    It is impossible to guess which library you have used. JQuery? MooTools? Prototype? Scriptaculous? Google API? Yahoo API? Other? It looks like you are not even aware of the fact that you are using a custom syntax of a certain library. Nor about the fact that a library have a different custom syntax than the base language, JavaScript.

    On the other hand, if you have used a "plug-in" of a certain library, all you have to do is to blame the creators of those codes. Or learn how to code your own javascript applications.

    Programming is a profession. You can not simply copy some codes written in a programming language from somewhere and complain lately that something does not work, without previously learning that language.
    Last edited by Kor; 11-09-2011 at 11:50 AM.
    KOR
    Offshore programming
    -*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*

  • #3
    New Coder
    Join Date
    Oct 2011
    Posts
    65
    Thanks
    1
    Thanked 0 Times in 0 Posts
    Dear Kor,
    I did say: It uses the mootols library, please check my post.
    so I do know the library, and Im just searching if there is an wellknown bug to help the author as it is a free code. I have told the author but are searching for myself. Thanks anyway

  • #4
    Kor
    Kor is offline
    Red Devil Mod Kor's Avatar
    Join Date
    Apr 2003
    Location
    Bucharest, ROMANIA
    Posts
    8,478
    Thanks
    58
    Thanked 379 Times in 375 Posts
    Quote Originally Posted by helenp View Post
    Dear Kor,
    I did say: It uses the mootols library, please check my post.
    so I do know the library, and Im just searching if there is an wellknown bug to help the author as it is a free code. I have told the author but are searching for myself. Thanks anyway
    OK, sorry. Yet, you should have started your Post with that information.

    I will move the thread to the specialized section of the Forum, called JavaScript Frameworks (http://codingforums.com/javascript-frameworks/). It looks like you have not seen it, same as I have not seen the world mootools, written in lowercase somewhere in the middle of a phrase.

    And I will insert a Prefix, in order to signal that is a MooTools problem
    KOR
    Offshore programming
    -*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*

  • #5
    New Coder
    Join Date
    Oct 2011
    Posts
    65
    Thanks
    1
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by Kor View Post
    OK, sorry. Yet, you should have started your Post with that information.

    I will move the thread to the specialized section of the Forum, called JavaScript Frameworks (http://www.codingforums.com/forumdisplay.php?f=62). It looks like you have not seen it, same as I have not seen the world mootools, written in lowercase somewhere in the middle of a phrase.

    And I will insert a Prefix, in order to signal that is a MooTools problem
    Thanks a lot

  • #6
    New Coder
    Join Date
    Oct 2011
    Posts
    65
    Thanks
    1
    Thanked 0 Times in 0 Posts
    Just discovered the issue is a cache issue (or not repeat issue).
    I have the same script (slideshow) in 36 pages, and with the cache clean I go to first page, gets the loading image for the first image only, then go to next page and to my surprise I dont get any loading image even for the first image.
    So then I add a no cache for the .gif files in htaccess, and with the no cache I get the loading image on the first image on all pages...but only on first image. So the bug consists in something as only display once, dont repeat if is in cache....
    If anybody have a clue....


  •  

    Posting Permissions

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