How can I limit the maximum number of characters a user can type in a field?
You may find yourself in the situation where you want your users to provide a postal code that is at most 4 characters long, or a description of themselves in less than 140 characters. In these cases the Maximum Character Length Add-On for Profile Builder comes in handy.
So to answer the above question, let me walk you through the 3 easy steps of getting this feature up and running.
Download and activate
First of all, click on the button below to download the add-on. Unzip the downloaded file and copy the contents in the wp-content/plugins directory.
Download The Maximum Character Length Add-On
Please note: The Maximum Character Length Add-On requires Profile Builder version 2.0.5 or higher.
Once the files are moved, head over to the Plugins section of the Dashboard and activate the add-on.
Set the maximum character length
Once the add-on has been activated head over to the Manage Fields page in Profile Builder. If you select an input field, a textarea field or the default biographical info field you will see that a new property named Maximum Character Length appeared below the other properties. All you need to do is set the desired value, in my case it was 10. You can also modify this value when editing one of these fields.
See it in action
Too see your work in action head over to the page where you display the register or edit form and type something in the field that has a maximum value set. Did it stop you from typing?
The post Maximum Character Length Add-On for Profile Builder appeared first on Cozmoslabs.