When a support user adds a school in Manage school placements, we use an autocomplete to help users search for schools.
The autocomplete works well for quickly selecting a school, but it requires JavaScript. Not everyone has JavaScript, and it doesn’t always run successfully.
We added a no-JavaScript version of the ‘Add organisation’ flow, which we can progressively enhance.
How it works
Selecting ‘School’ on the organisation type page takes the user to a form where they can search for a school, university or college. They do this by entering the school name, unique reference number (URN) or postcode.
Without JavaScript, when the user continues, we show:
- the number of results and the search term in the heading - for example, “7 results found for ‘challoner’”
- a way to change the search if the school they are looking for is not listed or if there are too many results
- a list of radio options matching their search query - we limit this list to 15 items
We use data provided by Get information about schools (GIAS).
We display the name, town and postcode for each school, university or college in the list. This allows users to correctly choose from similarly named locations.
Selecting a school from the list allows the user to continue and add the school.
If the user tries to continue without selecting a school, we show an error message:
Select a school
If the user tries to add a school a second time, we show an error message:
School has already been added
If the school the user is looking for isn’t listed or there aren’t any results, the user can change their search, which takes them back to the initial search form.
Screenshots#
Finding a school - without autocomplete#
![Screenshot of Finding a school - without autocomplete](schools--find.png)
List of schools - many results#
![Screenshot of List of schools - many results](schools--list-01.png)
List of schools - less than 15 results#
![Screenshot of List of schools - less than 15 results](schools--list-02.png)
List of schools - one result#
![Screenshot of List of schools - one result](schools--list-03.png)
No results#
![Screenshot of No results](schools--list-04.png)
Error message - Select a school#
![Screenshot of Error message - Select a school](schools--list-error-empty.png)
Error message - Scholl has already been added#
![Screenshot of Error message - Scholl has already been added](schools--list-error-duplicate.png)