0 and !is_numeric($cat)){ // to check if $cat is numeric data or not. echo "Data Error"; exit; } //@$cat=$HTTP_GET_VARS['cat']; // Use this line or above line if register_global is off ///////// Getting the data from Mysql table for first list box////////// $quer2=mysql_query("SELECT DISTINCT id_kat ,onoma_kat FROM m_katefthinsis order by id_kat"); ///////////// End of query for first list box//////////// /////// for second drop down list we will check if onoma_kat is selected else we will display all the subonoma_kat///// if(isset($cat) and strlen($cat) > 0){ $quer=mysql_query("SELECT DISTINCT onoma_math, id_math FROM m_sidelestes where id_kat=$cat order by id_math"); }else{$quer=mysql_query("SELECT DISTINCT onoma_math, id_math FROM m_sidelestes where id_kat=9 order by id_math"); } ////////// end of query for second subonoma_kat drop down list box /////////////////////////// echo "
"; /// Add your form processing page address to action in above line. Example action=dd-check.php//// ////////// Starting of first drop downlist ///////// echo "

Καλοδήμος Δημήτρης-www.sep4u.gr.

"; echo "

Υπολογισμός Μορίων απο τα Προφορικά και τα Γραπτά"; echo "

"; ////////////////// This will end the first drop down list /////////// ////////// Starting of second drop downlist ///////// $pr= "

Οι δεκαδικοί βαθμοί πρόσβασης να γράφονται με την μορφή: 17.5 και ΟΧΙ 17,7 (οχι κόμμα)"; echo "

"; if(strlen($cat) > 0){ echo ""; echo ""; } $i=1; while($noticia = mysql_fetch_array($quer)) { echo ""; $i=$i+1; } echo "
Προφορικός Γραπτός
$noticia[onoma_math]
"; ////////////////// This will end the second drop down list /////////// //// Add your other form fields as needed here///// if(strlen($cat) > 0){ $pr .= "

"; echo "$pr"; } echo "

"; ?>