# listBox + php question

**URL:** <https://forum.kirupa.com/t/listbox-php-question/42412>\
**Category:** flash\
**Created:** [February 8, 2004, 11:28pm UTC](https://forum.kirupa.com/t/listbox-php-question/42412 "2004-02-08T23:28:08Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ryall](https://avatars.discourse-cdn.com/v4/letter/r/53a042/32.png) [@Ryall](https://forum.kirupa.com/u/Ryall)\
**Post date:** [February 8, 2004, 11:28pm UTC](https://forum.kirupa.com/t/listbox-php-question/42412/1 "2004-02-08T23:28:08Z")

</div>

Hey guys…lame question here, but I’ve been away from flash for a while:

I have an order form that sends its vars to a php file which formats the data and then mails it to an address. All my text inputs work fine and show up in the email… however I am using a list box component and cannot seem to get its value set to a var and then sent to the php.

here is the AS I am using (for the submit button), very simple:

```php

on (release) {
	jumpType.getSelectedItem = "jumpType";
	if (name eq "" or address eq "" or city eq "" or phone eq "" or rentalDate eq "") {
		gotoAndStop(2);
	} else {
		
		loadVariablesNum("order.php", 0, "POST");
		gotoAndStop(3);
	}
}

```

the instance name for the listBox is “jumpType” and I would like toget the item selected by the user assign it to a var “jumpType” which would be sent to my php script… please show me what I am doing wrong – I know it is something simple.

Peace

---

<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:** [February 8, 2004, 11:32pm UTC](https://forum.kirupa.com/t/listbox-php-question/42412/2 "2004-02-08T23:32:31Z")

</div>

Maybe Kirupa’s listbox tutorial will be of some assistance.

[Just click right here to check it out.](http://www.kirupa.com/developer/mx/listbox.htm)

---

<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:** [February 8, 2004, 11:40pm UTC](https://forum.kirupa.com/t/listbox-php-question/42412/3 "2004-02-08T23:40:35Z")

</div>

ok I’ve changed the code and now it is returning a value in the formatted email, **BUT** it is returning this:

“[object Object]”

here is the new code I am using:

```php
on (release) {
	var jumpType= jumpType.getSelectedItem();
	if (name eq "" or address eq "" or city eq "" or phone eq "" or rentalDate eq "") {
		gotoAndStop(2);
	} else {
		
		loadVariablesNum("order.php", 0, "POST");
		gotoAndStop(3);
	}
}

```

---

<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:** [February 8, 2004, 11:49pm UTC](https://forum.kirupa.com/t/listbox-php-question/42412/4 "2004-02-08T23:49:00Z")

</div>

got it… I just needed to use this line instead:

```php
var jumpType = jumpType.getValue();

```

Peace
