# Loading jpg's using loadMovie and createEmptyMovieClip

**URL:** https://forum.kirupa.com/t/loading-jpgs-using-loadmovie-and-createemptymovieclip/213687
**Category:** flash
**Created:** [January 22, 2007, 3:36pm UTC](https://forum.kirupa.com/t/loading-jpgs-using-loadmovie-and-createemptymovieclip/213687 "2007-01-22T15:36:12Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![FlashNewby](https://avatars.discourse-cdn.com/v4/letter/f/5f8ce5/32.png) [@FlashNewby](https://forum.kirupa.com/u/FlashNewby)
#### Post date: [January 22, 2007, 3:36pm UTC](https://forum.kirupa.com/t/loading-jpgs-using-loadmovie-and-createemptymovieclip/213687/1 "2007-01-22T15:36:12Z")

</div>

Hi  
I’m trying to load a non-progressive jpg using loadMovie but not seeing the actual image show up in the movie clip. I’m using a xml file to read the path to the image so that I can load it. Can someone look over my short code and see if something looks wrong with how I’m loading it. The section to look at is in bold.

xmlData = new XML();  
xmlData.ignoreWhite = true;  
xmlData.onLoad = loadXML;  
stop();  
xmlData.load(“[http://www.somename.com/polldata.xml](http://www.somename.com/polldata.xml)”);  
var tag;  
var tagdata;  
function loadXML(loaded) {  
if (loaded) {  
xmlNode = this.firstChild; //root node of polldata.xml  
total = xmlNode.childNodes.length;  
//trace("total is: " + total);  
tag = xmlNode.childNodes[total-1].nodeName;

\*\*if(tag == “timage”){  
tagdata = xmlNode.childNodes[total-1].firstChild;  
\_root.createEmptyMovieClip(“pollMC”,1);  
pollMC.loadMovie(tagdata, “pollMC”);  
pollMC.\_x = 12;  
pollMC.\_y = 11.9

trace(tagdata);  
}\*\* }else {  
content = “file not loaded!”;  
}  
} // end loadXML
