EDIT:
With the hints on the responses i got to know that name isn't a valid attribute for div tag, but it's for select.
function modifica(estado,numero){
alert(numero);
$.ajax({
type: "GET",
datatype: "html",
url: "icallverifica.php",
data: {
estado : estado,
modifica : "1" ,
numero : numero
},
success: function(data) {
alert(data);
}
});
}
So, i want to get multiple attributes at once using onchange:
if($valor == 0){
mysql_select_db("iloja_icall", $con);
$result1 = mysql_query("SELECT * FROM icall WHERE verifica='0'");
while($row = mysql_fetch_array($result1)){
echo $row['numero'].'<select id="optin" name="'.$row['numero'].'" onchange="modifica(this.value,this.name)">
<option value="chamada">Chamada</option>
<option value="atendeu">Atendeu</option>
<option value="atendeunao">Nao atendeu</option>
<option value="engano">Engano</option>
</select>';
echo '<br>';
}
}
THIS COMBO IS NOW WORKING FLAWLESSLY :D THANK YOU SO MUCH GUYS, this is why i love stackoverflow :)
Shouldn't this work?
Thanks so much guys!