How to make an advanced search in php mysql

Hallo Guys, I am implementing a n online job application and in the back end I need a search criteria i= to search applicants by Position applied, Search by qualification e'g drop down with Bsc Comp science etc, and search by age which right now does even appear feasible to me as i have a field called date of birth of course we cant put age in the db Any suggestion link sample code will do me a lot of good Regards and Merry Xmass and a happy new year

if you are capturing date of birth of the applicant then you can infer the age. assuming you have a drop down with the age e.g. from 18 to 55 then you can easily extract the data using the sample code below $age = intval($_POST["age"]); // posted age e.g 18; $sql = "select * from applicants where qualification = 'selected Qualification' and year(now()) - year(dateofBirthOfApplicant) = $age "; On Tue, Dec 22, 2009 at 6:50 AM, Calvin Omari <calvinebarongo@gmail.com>wrote:
Hallo Guys,
I am implementing a n online job application and in the back end I need a search criteria i= to search applicants by Position applied, Search by qualification e'g drop down with Bsc Comp science etc, and search by age which right now does even appear feasible to me as i have a field called date of birth of course we cant put age in the db
Any suggestion link sample code will do me a lot of good
Regards and Merry Xmass and a happy new year
_______________________________________________ Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Server donations spreadsheet
http://spreadsheets.google.com/ccc?key=0AopdHkqSqKL-dHlQVTMxU1VBdU1BSWJxdy1f... ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke Other lists ------------- Announce: http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks-announce Science: http://lists.my.co.ke/cgi-bin/mailman/listinfo/science kazi: http://lists.my.co.ke/cgi-bin/mailman/admin/kazi/general

Thanks that is qute let me give it a try On Tue, Dec 22, 2009 at 10:19 AM, Chris Mwirigi <mwirigic@gmail.com> wrote:
if you are capturing date of birth of the applicant then you can infer the age. assuming you have a drop down with the age e.g. from 18 to 55 then you can easily extract the data using the sample code below
$age = intval($_POST["age"]); // posted age e.g 18; $sql = "select * from applicants where qualification = 'selected Qualification' and year(now()) - year(dateofBirthOfApplicant) = $age ";
On Tue, Dec 22, 2009 at 6:50 AM, Calvin Omari <calvinebarongo@gmail.com>wrote:
Hallo Guys,
I am implementing a n online job application and in the back end I need a search criteria i= to search applicants by Position applied, Search by qualification e'g drop down with Bsc Comp science etc, and search by age which right now does even appear feasible to me as i have a field called date of birth of course we cant put age in the db
Any suggestion link sample code will do me a lot of good
Regards and Merry Xmass and a happy new year
_______________________________________________ Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Server donations spreadsheet
http://spreadsheets.google.com/ccc?key=0AopdHkqSqKL-dHlQVTMxU1VBdU1BSWJxdy1f... ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke Other lists ------------- Announce: http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks-announce Science: http://lists.my.co.ke/cgi-bin/mailman/listinfo/science kazi: http://lists.my.co.ke/cgi-bin/mailman/admin/kazi/general
_______________________________________________ Skunkworks mailing list Skunkworks@lists.my.co.ke http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks ------------ Skunkworks Server donations spreadsheet
http://spreadsheets.google.com/ccc?key=0AopdHkqSqKL-dHlQVTMxU1VBdU1BSWJxdy1f... ------------ Skunkworks Rules http://my.co.ke/phpbb/viewtopic.php?f=24&t=94 ------------ Other services @ http://my.co.ke Other lists ------------- Announce: http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks-announce Science: http://lists.my.co.ke/cgi-bin/mailman/listinfo/science kazi: http://lists.my.co.ke/cgi-bin/mailman/admin/kazi/general
participants (2)
-
Calvin Omari
-
Chris Mwirigi