Griekis Posted June 23, 2006 Report Share Posted June 23, 2006 (edited) Ir divi JumpMenu. Bet neizdodas realizet to lai Otraa JumpMenu atlasa atkariiba no pirmaa izveeleetiem kriteeriijiem. Piemeeram. 1.ir krāsas, bet otrā automašīnas 1.JumpMenu ir "Sarkans,zaļs,Zils" 2.Ja pirmā izvēlas Sarkans tad raada tikai Sarkanas automašīnas. Doma ir kad izvēlas pirmaa JumpMenu tad norefresho un pado kraasu id. Bet neizdodas tas refresh un iisti visu lapu refreshot ar nevajag... Paldies!!! Nu kods ir apmēram tāds <select name="krasa" onChange="MM_jumpMenu('parent',this,0)"> <? $query=mysql_query("SELECT * FROM krasa"); echo "<option>--- --- ---|||--- --- ---"; while ($row =@ mysql_fetch_array($query)) { $id_krasa = $row[id_krasa]; $krasa=$row[krasa]; echo "<option value=\"$id_krasa\" target=\"info\">$id_krasa</option>"; } ?> </select> //Otra izlēcošā izvēle <select name="auto" onChange="MM_jumpMenu('parent',this,0)"> <? $query=mysql_query("SELECT * FROM auto where id_krasa=$id_krasa"); echo "<option>--- --- ---|||--- --- ---"; while ($row =@ mysql_fetch_array($query)) { $id_auto = $row[id_auto]; $auto=$row[auto]; echo "<option value=\"$id_auto\" target=\"info\">$auto</option>"; } ?> </select> Edited June 23, 2006 by Griekis Link to comment Share on other sites More sharing options...
v3rb0 Posted June 23, 2006 Report Share Posted June 23, 2006 un te visi zina ko tu sauc par JumpMenu? Link to comment Share on other sites More sharing options...
Griekis Posted June 23, 2006 Author Report Share Posted June 23, 2006 Nevajag taisīt muļķīgas QUOTEs Nu parJumpMenu sauc izlēcošā izvēle. Link to comment Share on other sites More sharing options...
Delfins Posted June 23, 2006 Report Share Posted June 23, 2006 Tipa komboboksis, izvēloties, pārlec uz citu lapu? Bet neizdodas tas refresh un iisti visu lapu refreshot ar nevajag... AJAX, attiecīgi būs jāparraksta JS un PHP kods.. Link to comment Share on other sites More sharing options...
Griekis Posted June 23, 2006 Author Report Share Posted June 23, 2006 Nevajag taisīt muļķīgas QUOTEs Nu uz citu lapu lai paarlec nevajag. Vajag lai varu izveeleeties 2 kriteerijus, kraasu un automasiinu. Kad izveelos kraasu otraa izvelee ir tikai taadaa kraasaa kaa izzveeleejos. Un kad shie abi kriteeriiji izveeleeti tad atlasa un paarlec uz citu lapu... Link to comment Share on other sites More sharing options...
Delfins Posted June 23, 2006 Report Share Posted June 23, 2006 AJAX, vai predefinēti JS-masīvi Link to comment Share on other sites More sharing options...
Recommended Posts