$rec?$rec:$next_end; echo "
Results $next_start to $last_val of $rec records\n"; } function print_ahref($nextstart,$limit,$more,$rec) { if (($nextstart-$limit) > 0) { $prev_start=$nextstart-$limit; $ahref_str="[ Previous Results ]"; echo "    $ahref_str\n"; } if ($more) { $nextstart=$nextstart+$limit; $ahref_str="[ Next Results ]"; echo " $ahref_str
\n"; } echo "

\n"; } //end function -------------------------------------------------------------------------------------------------------------------------------------- include ("dbhost.php3"); $db = mysql_connect($host, $user, $pass); mysql_select_db($dbname,$db); $next_start = 0; $next_end = 0; $display_limit = 25; if(!$nextstart) { $next_start = 1; } else { $next_start = $nextstart; } $next_end = $next_start + $display_limit - 1; if ($submit) { $test=false; if($submit == age) { switch ($year) { case 1: $sql = "SELECT * FROM info_final WHERE year between 1941 and 1945 and sex='$sex'"; $result = mysql_query($sql); break; case 2: $sql = "SELECT * FROM info_final WHERE year between 1946 and 1950 and sex='$sex'"; $result = mysql_query($sql); break; case 3: $sql = "SELECT * FROM info_final WHERE year between 1951 and 1955 and sex='$sex'"; $result = mysql_query($sql); break; case 4: $sql = "SELECT * FROM info_final WHERE year between 1956 and 1960 and sex='$sex'"; $result = mysql_query($sql); break; case 5: $sql = "SELECT * FROM info_final WHERE year between 1961 and 1965 and sex='$sex'"; $result = mysql_query($sql); break; case 6: $sql = "SELECT * FROM info_final WHERE year between 1966 and 1970 and sex='$sex'"; $result = mysql_query($sql); break; case 7: $sql = "SELECT * FROM info_final WHERE year between 1971 and 1975 and sex='$sex'"; $result = mysql_query($sql); break; case 8: $sql = "SELECT * FROM info_final WHERE year between 1976 and 1980 and sex='$sex'"; $result = mysql_query($sql); break; case 9: $sql = "SELECT * FROM info_final WHERE year between 1981 and 1985 and sex='$sex'"; $result = mysql_query($sql); break; case 10: $sql = "SELECT * FROM info_final WHERE year between 1986 and 1990 and sex='$sex'"; $result = mysql_query($sql); break; } } elseif($submit == cast) { $sql = "SELECT * FROM info_final WHERE cast='$cast' and sex='$sex'"; $result = mysql_query($sql); } elseif ($submit == religion) //for religionwise search { $sql = "SELECT * FROM info_final WHERE religion='$religion' and sex='$sex'"; $result = mysql_query($sql); $var=true; } elseif ($submit == status) //for statuswise search { $sql = "SELECT * FROM info_final WHERE mstatus='$mstatus' and sex='$sex'"; $result = mysql_query($sql); $var=true; } elseif ($submit == physical_status) //for physical status wise search { $sql = "SELECT * FROM info_final WHERE physical_status='$physical_status' and sex='$sex'"; $result = mysql_query($sql); $var=true; } if ($myrow = mysql_fetch_array($result)) { echo "\n"; echo ""; echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; echo "\n"; $i = $next_start; $j = $next_end>mysql_num_rows($result)?mysql_num_rows($result):$next_end; do { mysql_data_seek($result,$i-1); $myrow = mysql_fetch_array($result); printf("", $myrow["code"]); printf("", "mixed.php3", $myrow["fname"], $myrow["fname"]); printf("", $myrow["date"], $myrow["month"], $myrow["year"]); printf("", $myrow["cast"]); printf("", $myrow["religion"]); printf("", $myrow["education"]); printf("", $myrow["preference"]); printf("", $myrow["mstatus"]); printf("", $myrow["physical_status"]); $i++; } while ($i<=$j); echo "
CodeNameBirth DateCasteReligionEducationPreferenceStatusPhysical
Status
%s%s%s-%s-%s%s%s%s%s%s%s
\n"; many_records(mysql_num_rows($result),$next_start,$next_end); $still_more = (mysql_num_rows($result) > $next_end)?1:0; if (mysql_num_rows($result) > $display_Limit) { print_ahref($next_start,$display_limit,$still_more,mysql_num_rows($result)); } } else { echo "
No records founds

"; echo "Back
"; } } else { if($test1) { ?>





Name
Birth Date -- Birth Time
Birth Place Birth Country
Weight Kg. Height C.M.
Skin / Complexion Spectacles
Religion Caste
Mothor Tongue Mosal
Brothers Sisters
Family Native Place
Other Language known Food-Habit
       
Present Resident Address
City Pin / Zip
Province / State Country
       
Present Business Profession Job Address    
City Pin / Zip
Province / State Country
       
Resident Phone Office Phone
Fax No. Mobile No.
Email ID Education
       
Brief details of your Family, Financial, Status / Business / Profession / Job and Choice
       
Preference Marital Status
Sex Physical Status
       


Back
\n"; echo "Code"; echo "Name\n"; echo "Birth Date\n"; echo "Caste\n"; echo "Religion\n"; echo "Education\n"; echo "Preference\n"; echo "Status\n"; echo "Physical
Status
\n"; $i = $next_start; $j = $next_end>mysql_num_rows($result)?mysql_num_rows($result):$next_end; do { mysql_data_seek($result,$i-1); $myrow = mysql_fetch_array($result); printf("%s", $myrow["code"]); printf("%s", "mixed.php3", $myrow["code"], $myrow["fname"]); printf("%s-%s-%s", $myrow["date"], $myrow["month"], $myrow["year"]); printf("%s", $myrow["cast"]); printf("%s", $myrow["religion"]); printf("%s", $myrow["education"]); printf("%s", $myrow["preference"]); printf("%s", $myrow["mstatus"]); printf("%s", $myrow["physical_status"]); $i++; } while ($i<=$j); echo "\n"; //echo "
Back || Registration
\n"; many_records(mysql_num_rows($result),$next_start,$next_end); $still_more = (mysql_num_rows($result) > $next_end)?1:0; if (mysql_num_rows($result) > $display_Limit) { print_ahref($next_start,$display_limit,$still_more,mysql_num_rows($result),$QUERY_STRING); } } else { echo "
Sorry, no records were found!"; echo "

Back || Registration
"; } } } ?>