carlosgonca
10-28-2009, 07:28 PM
version :Flash Cs4 - actionscript 2.0 - combobox component
I use this code in flash:
myLabels = new Array ("Deleite","Light","0% Colesterol","Limão","Regular","Atum","Azeitona","Alho","Tártaro","Filé Grelhado");
// Populate the listbox
for (i=0;i<myLabels.length;i++) {
produtos.addItem (myLabels[i]) ;
}
// Display function
function listDisplay (component) {
lista = component.getSelectedItem().label ;
}
// You get the picture
produtos.setChangeHandler ("listDisplay") ;
where "products" are the instance name of component combobox and "lista" the variable to get the option choosen
in php I put this:
$recebenome = $_POST['nome'];
$recebemail = $_POST['email'];
$recebeidade = $_POST['idade'];
$recebeproduto = $_POST['lista'];
but I don't receive the 'lista' option choosen. What am I doing wrong?
I use this code in flash:
myLabels = new Array ("Deleite","Light","0% Colesterol","Limão","Regular","Atum","Azeitona","Alho","Tártaro","Filé Grelhado");
// Populate the listbox
for (i=0;i<myLabels.length;i++) {
produtos.addItem (myLabels[i]) ;
}
// Display function
function listDisplay (component) {
lista = component.getSelectedItem().label ;
}
// You get the picture
produtos.setChangeHandler ("listDisplay") ;
where "products" are the instance name of component combobox and "lista" the variable to get the option choosen
in php I put this:
$recebenome = $_POST['nome'];
$recebemail = $_POST['email'];
$recebeidade = $_POST['idade'];
$recebeproduto = $_POST['lista'];
but I don't receive the 'lista' option choosen. What am I doing wrong?