This content has been marked as final. Show 3 replies
Are you using a relative or absolute URL for the image? If it's relative, keep in mind that the base URL is different in the two cases.
hi thx for your answer.
I've tested both. Also i have created an image in my fla and give it a classname/ id .
Then i call it like that <img src = "myimg" ></img>
In Flash9 no Problem. In Adobe air .. no image is shown.
I've had the same problem. Using an img tag in a dynamically generated text field does not work the same published for AIR as it does published for Flash Player. If I use a relative path for the image or the class name of a symbol in the library in Flash it works perfectly, but neither work if the same code is published for AIR. Is there a solution to this that anyone knows of?
Here's an example:
var optionFont:Font = new UniversBold();
var optionFormat = new TextFormat();
optionFormat.color = 0x27318b;
optionFormat.bold = true;
optionFormat.size = 38;
optionFormat.font = optionFont.fontName;
var field:TextField = new TextField();
field.embedFonts = true;
field.autoSize = TextFieldAutoSize.LEFT;
field.defaultTextFormat = optionFormat;
field.selectable = false;
field.htmlText = "Hi There <img src='GTE38'> Hi There";
field.wordWrap = true;
field.width = 200;
addChild( field );
UniversBold and GTE38 are classes in the library. This works when published for Flash, but if republished for AIR, the image does not show up.