Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

loading image dynamically

Status
Not open for further replies.

stakadush

Programmer
Oct 1, 2001
195
IL
ok. i will start with my script:
Code:
sTextA = "loading...";

newTextA = &quot;<font face=\&quot;Verdana, Helvetica, Arial\&quot; size=\&quot;-1\&quot;>&quot;;
for (i = 0; i < numEvents; i++) {
	eventTitle = this[&quot;eventTitle&quot;+i];
	eventCountry = this[&quot;eventCountry&quot;+i];
	eventDate = this[&quot;eventDate&quot;+i];
	eventFlyer = this[&quot;eventFlyer&quot;+i];

	newTextA += &quot;<b>&quot;+ eventDate +&quot;</b>&quot;;
	newTextA += &quot; @ &quot;;
	if (eventFlyer != &quot;&quot;) {
		newTextA += &quot;<u><a href=\&quot;&quot;+ imagesDir +&quot;/&quot;+ eventFlyer +&quot;\&quot;>&quot;;
	}
	newTextA += eventTitle;
	if (eventFlyer != &quot;&quot;) {
		newTextA += &quot;</a></u>&quot;;
	}
	newTextA += &quot; [&quot; + eventCountry + &quot;]&quot;;
	newTextA += &quot;<br>&quot;;
}
newTextA += &quot;</font>&quot;;

sTextA = newTextA;
i use php to send the data to flash. everything works well.
what i want to add is an image for every item that has a flyer (if (eventFlyer != &quot;&quot;) condition). i thought of using attachMovie but i can't seem to find a way to attache it in place (for example at the beginning of every line that has a flyer).

another thing is that i would like to use an href with a javascript to define the new page to open the flyer in (something like
Code:
<a href=\&quot;javascript:open(&quot;+ eventFlyer +&quot;, 'flyer', 'toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=no,resizable=no,copyhistory=no,width=500,height=400')\&quot;>&quot;+ eventTitle +&quot;</a>
).

any ideas? i'm really stuck... :)
thanks (-:
 
Erm the only thing I can think to do for the images (and don't necessarily take my word for it!) is to pop your image into a movie, save it as an swf and then do a movieload. You can resize / position your movie as necessary once it has been loaded and also do tests, etc, to see if it has loaded.

=)

PetitPal.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top