hello
I have a form which have 5 drop down boxes which contains the initial values now this is my database I want to make a search result page in php which displays a single record with have following validations:

  1. if all options (college, class, rollnumber, student_name, section) vaules will be --- or blank then redirect to select.php page (i.e. main page)
  2. student_name is not required in all cases it can be blanked but not all others
  3. college, class, rollnumber, student_name, section all fields are strictly to be match with a database tables and shows only a certain 1 result of profile details
  4. profile_detail table contains HTML value in database and profile_detail is a result which I want to display

If some one help me in this i'll be very thanks

CREATE TABLE IF NOT EXISTS `wizresult` (
`id` int(11) NOT NULL auto_increment,
`college` varchar(255) NOT NULL,
`class` varchar(255) NOT NULL,
`rollnumber` varchar(255) NOT NULL,
`student_name` varchar(255) NOT NULL,
`section` varchar(255) NOT NULL,
`profile_detail` longtext NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;

Set JS validation for all without student name select box, So the user should enter all the combo boxes . Thus you can display result by using

SELECT * from table_name WHERE studentname = '$studentname' OR college = '$college' AND class = '$class' AND rollnumber = '$rollnum' AND section = '$section';
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.