Field Patterns Example Patterns and Validation with custom messages The following fields will only be accepted if they meet the pattern when set to 'required' in modern browsers. The 'User Name' field has a custom validation message added using the 'data-validity' attribute. Inspect element to view example. User Name pattern="[a-zA-Z]{1,50}" Enter Username (no spaces or special chars, 1-50 chars) Address pattern="[a-zA-Z0-9\s]+" Enter Street Address (no special chars) Postal Code pattern="(\d{5}([\-]\d{4})?)" Enter Postal Code (no space, no special chars, accepts 88888 or 88888-8888) Submit Legacy Style Fieldsets Example Legacy [narrow] layout The following fields are a legacy type view but done using flexbox Label Example Label which is a tad longer Example text going on here Back Submit