Forum Webmastera, HTML, CSS, PHP, MySQL, Hosting, Domeny - Forum dla Webmasterów
[js] Tablica nie jest tworzona. - Wersja do druku

+- Forum Webmastera, HTML, CSS, PHP, MySQL, Hosting, Domeny - Forum dla Webmasterów (https://www.webmastertalk.pl)
+-- Dział: Technologie internetowe - tworzenie stron WWW (https://www.webmastertalk.pl/forum-technologie-internetowe-tworzenie-stron-www)
+--- Dział: xHTML, CSS, JavaScript (https://www.webmastertalk.pl/forum-xhtml-css-javascript)
+--- Wątek: [js] Tablica nie jest tworzona. (/thread-js-tablica-nie-jest-tworzona)



[js] Tablica nie jest tworzona. - kbzium - 31-08-2011

Cześć,

Poniżej prosty kod. Nie umiem znaleźć błędu. Firebug również nie komunikuje nic. Alertowałem to sobie i wynika z tego, że funkcja wysypuje się po miejscu oznaczonym gwiazdką. Dlaczego? Wszystkie zmienne mają prawidłowe wartości, sprawdzałem...


Kod:
iterQueue = 0;
    var i = 0;
    
        $.ajax({
            type: "GET",
            url: "nav/res/feat_data.xml",
            dataType: "xml",
            success: function(xml) {
                var entry = $(xml).find("entry");
                featQueue = new Array(entry.length);
                
                entry.each(function() {
                    var children = $(this).children();
                    featQueue[i] =  new Array(children.length);
                    
                    featQueue[i][0] = children.first().text();
                    featQueue[i][1] = children.nextSibling().text();
                    
                    i++;
                });                
            }
        });