Anjali Khan

Anjali Khan

  • NA
  • 867
  • 224.7k

i want if i will the proper data so textbox should not be ap

Aug 22 2016 1:42 AM

hi if i fill the registration form it is submitted..

on button click i created runtime textbox...

but once i fill the proper data and submit the button  textbox is showing then disiable..

i want if i will the proper data so textbox should not be apper..


code <p>
            <input id="btnAdd" type="SUBMIT" value="Register" onclick="AddTextBox()" />
        </p>

        <div id="TextBoxContainer">
            <!--Textboxes will be added here -->
        </div>
    </fieldset>
}
   <script type="text/javascript">

               function GetDynamicTextBox(value){
               return '<input name = "DynamicTextBox" type="text" value = "' + value + '" />'            
           }
              var count=0;
              function AddTextBox()
              {
                  if (count <= 1) {
                      var div = document.createElement('DIV');
                      div.innerHTML = GetDynamicTextBox("");
                      document.getElementById("TextBoxContainer").appendChild(div);                 
                      //count++;
                  }
              }
</script>


Answers (4)