When setting up the 'Configuration' of your Launchpad you will be asked the question:

'Ask your learners for information to help you identify them?'

If you choose this option, you will be given the option to 'Add an identification field'.

There are several fields types that you can choose from, Name, Date, Country and Text. 

If you choose the option 'Text', this will add a free text field to the registration page that your learners encounter when they access your content. 

As this is a free text field, we offer the option to apply Regular expressions to these fields to restrict what will be accepted.

You can only apply Regular Expression to a field that is using the 'Field type' of 'Text'.

Take this example I have a text field set up where I would like learners to enter their employee ID:

...this configuration means that: 

  • There will be text in the field that says 'Please enter your employee ID', this is determined by the 'Field label' field on the configure menu.
  • If the ID that is entered is not in the recognised format the text 'Employee ID is required' will appear:

...this is determined by the 'Error text' field on the configure menu.

  • To determine the recognised format, in the 'Regular Expression' field on the Configure menu an expression has been added which will mean that only numbers and letters can be added

Using these options you can get a variety of other outcomes, in order to help you get started, here are some commonly used expressions, just copy them into the 'Regular expression' field:

Only accept lower case letters: 

[a-z]+

Only accept upper case letters: 

[A-Z]+

Only accept letters: 

[a-zA-Z]+

Only accept a word of 5 letters minimum: 

[a-zA-Z]{5}

Only accept a word of 5 letters exactly: 

^[a-zA-Z]{5}$

Only accept numbers: 

[0-9]+

Only accept numbers between: 

[0-5]+

If you have something more adventurous in mind here are some resources:

https://regex101.com/

...this site will allow you to check whether your expression works.

https://www.rexegg.com/regex-quickstart.html

...an excellent cheat sheet which can be used to remind yourself of expressions and learn new ones.

Please note that due to the vast amount of combinations that can be achieved with Regular Expressions our support team are not able to assist with composing them. 

Did this answer your question?