# God help me ! Dam PHP loop to Flash

**URL:** <https://forum.kirupa.com/t/god-help-me-dam-php-loop-to-flash/116751>\
**Category:** Uncategorized\
**Created:** [July 21, 2004, 3:23am UTC](https://forum.kirupa.com/t/god-help-me-dam-php-loop-to-flash/116751 "2004-07-21T03:23:22Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![The\_Vulcan](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/the_vulcan/32/145_2.png) [@The\_Vulcan](https://forum.kirupa.com/u/The_Vulcan)\
**Post date:** [July 21, 2004, 3:23am UTC](https://forum.kirupa.com/t/god-help-me-dam-php-loop-to-flash/116751/1 "2004-07-21T03:23:22Z")

</div>

I hope someone can help me because I am about to give up.

**[color=blue]This is the PHP loop.[/color]**

```php
 
if($numallComments == 0) { print " No entries yet.."; }
 
else { while ($array = mysql_fetch_array($fewComments)) {
  
print "&writename[$i]="; $name = mysql_result($fewComments, $i, 'name'); print''. $name .'';
print "&writelocation[$i]="; $location = mysql_result($fewComments, $i, 'location');	print'<b>Location: </b><br>'. $location .'';
print "&writeage[$i]="; $dob = mysql_result($fewComments, $i, 'dob');
			 $today = date("Y"); 
			 $dob = $today - $dob; print'<b>Age: </b>'. $dob .'';
print "&writedate[$i]=";	$time = mysql_result($fewComments, $i, 'time');
			 $time = date("d-m-Y"); print'<b>Date: </b>'. $time .'';
print "&writecomments[$i]="; $comments = mysql_result($fewComments, $i, 'comments'); print'<b>Commnets: </b><br>'. $comments .'';
  
 $i++;
 
 }

```

[color=blue] **This is the Flash recieve and paste to duplicated movies.** [/color]

```php
 
myEntries = new LoadVars() 
 myEntries.ref = this
 myEntries.load("GuestBook.php?action=read&r="+random(999)+"&NumLow="+_parent.NumLow) 
 myEntries.onLoad = function(success){ 
  if(success){ 
   
ring.writename.text = this.writename;	  
ring.writeage.text = this.writeage;		  
ring.writedate.text = this.writedate;		  
ring.writelocation.text = this.writelocation; 
ring.writecomments.text = this.writecomments; 
   
for(i=0; i<3; i++){
eval("ring"+i).writename.text = this.eval("writename"+i);
eval("ring"+i).writeage.text = this.eval("writeage"+i);		
eval("ring"+i).writedate.text = this.eval("writedate"+i);
eval("ring"+i).writecomments.text = this.eval("writecomments"+i);
}

```

All I get is “_Undefined_”

I guess the error is in;  
**A.** the loop in PHP is not reading the data as I think it is.  
**B.** Flash in not recieving the data for some reason.

I hope someone can help me with this 🙂

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [July 21, 2004, 9:25am UTC](https://forum.kirupa.com/t/god-help-me-dam-php-loop-to-flash/116751/2 "2004-07-21T09:25:41Z")

</div>

Well I took a 3 hour nap…

My brain felt like I was drunk, just couldn’t think straight…  
But that’s what you get for sleeping 6 hours in 4 days (3 hours every second day).

So back to this dam loop that will be the death of me…

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [July 21, 2004, 11:17pm UTC](https://forum.kirupa.com/t/god-help-me-dam-php-loop-to-flash/116751/3 "2004-07-21T23:17:16Z")

</div>

Hey **Yeldarb**

Well I missed going to bed again, but I think my body is getting used to no sleep now. 🙂

Anyway yesterday when you where telling me what to do I was so far out of it didn’t know what was going on.

I couldn’t trace it because I didn’t have a local server set up.

last night I set up ISS, PHP, mySQL local but i can’t get phpMyAdmin to work.

I just posted here asking a question on that…

Yeah I can create tables from DOS, or load a text file, but I would rather get MyAdmin to work than stuff around with that. 🙂

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [July 21, 2004, 11:20pm UTC](https://forum.kirupa.com/t/god-help-me-dam-php-loop-to-flash/116751/4 "2004-07-21T23:20:18Z")

</div>

Wait, what? Why can’t you trace it? All I meant was just having it open a new browser window that would display what your php returned 😉

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [July 21, 2004, 11:33pm UTC](https://forum.kirupa.com/t/god-help-me-dam-php-loop-to-flash/116751/5 "2004-07-21T23:33:47Z")

</div>

Oh… well I did look into

sendAndLoad

but couldn’t figure it out…

I have myAdmin working now so I should be able to trace it in a minute, fingures crossed.
