Displaying Results

Once the connection to the database has been made and the forms are all created then next step was for me to use PHP to allow the data in the database to be displayed on the page, which means users would be able view the rooms. This process proved quite difficult for me to complete however with perseverance it was completed.

Below are screen shots of the code that makes the display possible.

Screen Shot 2015-04 Screen Shot 2015-04

The entries into the ‘house’ table of the database are displayed like below on the ‘search’ page of the web application.

Screen Shot22

Filtering

Designing A Filter Form

An important function for users to be able to do is to filter the results. There are over 12 different universities listed on our website therefore users would have to search through all results to find a room relevant to them. This is why the filter form is needed on the site to ensure users can access the vacant rooms with ease allowing the sites purpose to be met.

The first step for allowing this was for me to create a filter form in HTML code. Using the same CSS as the other forms on the site this was made easy, I decided to use the ‘select’ tags which created a drop down menu. This made the form look professional and use a small amount of space yet remain effective.

The result is displayed below:

filterform

Screen Shot 200

PHP Filter Code

Once the form was created PHP code has to be written which would then allow the connection to the database, this would ensure that users were able to filter the results to their needs.

Screen Shot

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s