# Loading link image

**URL:** <https://forum.kirupa.com/t/loading-link-image/133447>\
**Category:** Uncategorized\
**Created:** [January 8, 2005, 5:09pm UTC](https://forum.kirupa.com/t/loading-link-image/133447 "2005-01-08T17:09:57Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![vanbasten](https://avatars.discourse-cdn.com/v4/letter/v/35a633/32.png) [@vanbasten](https://forum.kirupa.com/u/vanbasten)\
**Post date:** [January 8, 2005, 5:09pm UTC](https://forum.kirupa.com/t/loading-link-image/133447/1 "2005-01-08T17:09:57Z")

</div>

Hi all

I create this script for to load images dynamically.  
Therefore I want click to this image as a link  
I create this script , the image is loaded but I can’t click it!  
Where am I wrong?  
thanks

createEmptyMovieClip(“photo”, 1);  
createEmptyMovieClip(“photo2”, 2);  
photo2.\_x=160;  
photo.loadMovie(“img1.jpg”);  
photo2.loadMovie(“img2.jpg”);

photo.onPress = function() {  
//code  
};  
photo2.onPress = function() {  
//code  
};
