# Using the \<img\> tags

**URL:** <https://forum.kirupa.com/t/using-the-img-tags/100949>\
**Category:** Uncategorized\
**Created:** [February 4, 2004, 3:23am UTC](https://forum.kirupa.com/t/using-the-img-tags/100949 "2004-02-04T03:23:20Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![3d\_Nirvana](https://avatars.discourse-cdn.com/v4/letter/3/a88e4f/32.png) [@3d\_Nirvana](https://forum.kirupa.com/u/3d_Nirvana)\
**Post date:** [February 4, 2004, 3:23am UTC](https://forum.kirupa.com/t/using-the-img-tags/100949/1 "2004-02-04T03:23:20Z")

</div>

Hi all!,

I’m trying to use the \<img\> tags to display a picture in my dynamically loaded text (from a .txt file) .

Here is the code I’m using to load my external text file:

on (release) {  
loadText = new LoadVars();  
loadText.load(“TEXT1.txt”);  
loadText.onLoad = function(success) {  
if (success) {  
textBox.html = true;  
textBox.htmlText = this.textContent;  
}  
};

}

Here is what is in my text file that I load:

\<img src=‘image.jpg’\>

The text that is also in my file loads and I can see that, the \<img\> tag code is invisible meaning it recognized it as code and did not display it as text. Even though the \<img\> text is gone it refuses to show my image. I have tried just about everything I know of and can’t get it to work.

Please help!

Thanx in advance

---

<div class="post-metadata">

**Author:** ![Visual\_Dialects](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/visual_dialects/32/688_2.png) [@Visual\_Dialects](https://forum.kirupa.com/u/Visual_Dialects)\
**Post date:** [August 12, 2004, 1:40am UTC](https://forum.kirupa.com/t/using-the-img-tags/100949/2 "2004-08-12T01:40:12Z")

</div>

I know this is an old thread but was hoping I could resurrect it.

I’m having similar problems to the guys above, I can get the image to load into my text field if I have the action on a frame, but as soon as I call for the action from a button it wont work?

Does anyone have any bright ideas?

Any help would be great.

Cheers, J
