Hi all I have following code:
<form>
<input type="text" id="FormField_6_input" name="CompanyName"/>
<button id="ContinueButton_6">Continue</button>
</form>
<script>
let companyNameField = document.getElementById('FormField_6_input');
companyNameField.setAttribute("pattern", "/[2-9]{1}\d{3}/");
companyNameField.setAttribute("title", "invalid input");
</script>
I want to add pattern and title attributes to my input but it not working please help me to resolve this problem.