Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I have a database called studentregistration where I want to display a page for a student to search on a column called ourseSemester in a

I have a database called studentregistration where I want to display a page for a student to search on a column called ourseSemester in a table named tblCourses. Then i want the search to return all hits.

I have get the page to display but it will not search properly.

Below is my PHP code to date for the search page - Note, I do know my config files works for opening and selecting the database since I am using it in other pages of my project.

prepare("select * tblCourses where courseSemester like '%$search%'"); $stmt->execute(); $course_details = $stmt->fetchAll(PDO::FETCH_ASSOC); //print_r($course_details); } else { $searchErr = "Please enter the information"; } } ?>

Online Course Search

University ABC - Online Course Finder


*

Search Result


No data found'; } else{ foreach($course_details as $key=>$value) { ?>

Course Code Course Name Semester Number of Available Seats
Course Selection

I have also attached a screen shot of the screen.

image text in transcribed

Search Course by Semester:: Course Selection Search Result No data found Course Code Course Name Semester Number of Available Seats

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions

Question

What region of the country had the biggest improvement in acid rain

Answered: 1 week ago

Question

Which form of proof do you find most persuasive? Why?

Answered: 1 week ago