# External xml jpeg wont' load when check online

**URL:** <https://forum.kirupa.com/t/external-xml-jpeg-wont-load-when-check-online/170813>\
**Category:** Uncategorized\
**Created:** [November 29, 2005, 6:10pm UTC](https://forum.kirupa.com/t/external-xml-jpeg-wont-load-when-check-online/170813 "2005-11-29T18:10:56Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![oxyde\_mac\_com](https://avatars.discourse-cdn.com/v4/letter/o/7c8e57/32.png) [@oxyde\_mac\_com](https://forum.kirupa.com/u/oxyde_mac_com)\
**Post date:** [November 29, 2005, 6:10pm UTC](https://forum.kirupa.com/t/external-xml-jpeg-wont-load-when-check-online/170813/1 "2005-11-29T18:10:56Z")

</div>

Hi,  
i have this annoying thing happening.  
i have this xml gallery working smoothly when working in local but my thumbnails images don’t show up when i check the website online.  
i’ve tried to use internet absolute path, local path, or the normal one but nothing happend.  
i trace the image to check if they load and they do and i can see they (local machine) why online i couldn’t see them.

thanks a lot for the help

here my gallery script:

//as much as i’ve checked it look ok…well i’m a newbee

var tnNr;  
spacing = 10;  
container.\_alpha = 0;  
var curLength;  
MovieClip.prototype.loadPic = function(pic, id) {  
info.text = “”;  
this.\_alpha = 0;  
this.loadMovie(pic);  
temp = this.\_parent.createEmptyMovieClip(“temp2”, 998);  
temp.onEnterFrame = function() {  
var t = container.getBytesTotal(), l = container.getBytesLoaded();  
if (Math.round(l/t) == 1 && container.\_width != 0 && container.\_height != 0) {  
var w = container.\_width+spacing, h = container.\_height+spacing;  
border.resizeMe(w, h, id);  
delete this.onEnterFrame;  
}  
};  
};

function galleryChoice(q) {  
pArray = new Array();  
tArray = new Array();  
iArray = new Array();  
my\_xml = new XML();  
for (var j = 0; j\<curLength; j++) {  
this.scroll.th\_nav[“thmb”+j].removeMovieClip();  
}  
my\_xml.ignoreWhite = true;  
my\_xml.onLoad = function(loaded) {  
if (loaded) {  
gallery = this.firstChild.childNodes[q];  
curLength = gallery.childNodes.length;  
for (var i = 0; i\<gallery.childNodes.length; i++) {  
pArray.push(gallery.childNodes\*.attributes.source);  
tArray.push(gallery.childNodes\*.attributes.thumb);  
iArray.push(gallery.childNodes\*.attributes.title);  
}  
}  
delay = setInterval(makeButtons, 50);  
};  
my\_xml.load(“work.xml”);  
}  
function makeButtons() {  
tnNr = 0;  
clearInterval(delay);  
for (var i = 0; i\<tArray.length; i++) {  
var thb = scroll.th\_nav.thmb.duplicateMovieClip(“thmb”+i, 1000+i);  
thb.id = i;  
thb.\_x = i%5\*115;  
thb.\_y = Math.floor(i/5)\*115;

```
}
loadButtons();

```

}  
function loadButtons() {  
var tbox = scroll.th\_nav[“thmb”+tnNr].box;  
tbox.loadMovie(tArray[tnNr]);  
temp = this.createEmptyMovieClip(“tmp”+tnNr, 999);  
temp.onEnterFrame = function() {  
bt = tbox.getBytesTotal();  
bl = tbox.getBytesLoaded();  
if (bt == bl && bt\>4) {  
nextButton();  
delete this.onEnterFrame;  
}  
};  
}  
function nextButton() {  
if (tnNr\<tArray.length-1) {  
tnNr++;  
loadButtons();  
} else {  
activateButtons();  
}  
}  
function activateButtons() {  
mainButtons();  
for (var i = 0; i\<pArray.length; i++) {  
var but = scroll.th\_nav[“thmb”+i];  
but.id = i;  
but.onRelease = function() {  
getURL(pArray[this.id], “\_blank”);  
};  
but.onRollOver = function() {  
this.\_alpha = 50;  
info.text = iArray[this.id];  
}  
but.onRollOut = function() {  
this.\_alpha = 100;  
}  
}  
container.loadPic(pArray[0], iArray[0]);  
disButtons2(0);  
}  
butArray = new Array();  
butArray = [“gal1\_btn”];  
function mainButtons() {  
for (var i = 0; i\<butArray.length; i++) {  
this[butArray\*].id = i;  
this[butArray\*].onRelease = function() {  
galleryChoice(this.id);  
disButtons(this.id);  
};  
}  
}  
function disButtons2(d) {  
for (var i = 0; i\<tArray.length; i++) {  
if (i != d) {  
this.scroll.th\_nav[“thmb”+i].enabled = 1;  
this.scroll.th\_nav[“thmb”+i].box.\_alpha = 100;  
} else {  
this.scroll.th\_nav[“thmb”+i].enabled = 1;  
this.scroll.th\_nav[“thmb”+i].box.\_alpha = 100;  
}  
}  
}  
function disButtons(d) {  
for (var i = 0; i\<butArray.length; i++) {  
if (i != d) {  
this[butArray\*].enabled = 1;  
this[butArray\*].gotoAndStop(1);  
} else {  
this[butArray\*].enabled = 0;  
this[butArray\*].gotoAndStop(2);  
}  
}  
}  
disButtons(0);  
galleryChoice(0);

//there you go for the xml

\<?xml version=“1.0” encoding=“UTF-8”?\>  
\<menu\>  
\<gallery name=“work”\>  
\<image source=“PReel/Buick-V8.mov” thumb=“work\_pics/th\_Buick.jpg” title=“Buick 30sec Director: Chen Tapu”/\>  
\<image source=“PReel/MC-Tarzan.mov” thumb=“work\_pics/th\_Tarzan.jpg” title=“MC Tarzan 30sec Director: Chen Tapu”/\>  
\<image source=“PReel/xingye.mov” thumb=“work\_pics/th\_xingye.jpg” title=“Xingye 30sec Director: Chen Tapu”/\>  
\<image source=“PReel/Bud.mov” thumb=“work\_pics/th\_bud.jpg” title=“Budweiser 30sec Director: Warren Klass”/\>  
\</gallery\>  
\</menu\>
