HTML 5 native validation is not working in JQuery UI model box but Jquery validation using plugin is working

HTML 5 native validation is not working in JQuery UI model box but Jquery validation using plugin is working

Hi All,

I am using a Jquery model box where HTML 5 native validation is not working.


Also I am adding the code below.

    <!DOCTYPE html>
    <html>
    <head>
    <title>jQuery UI Dialog: Open Dialog </title>
    <link rel="stylesheet" href="../css/jquery-ui.css" />
    <link rel="stylesheet" href="../css/style.css" />
    <script type="text/javascript" src="../scripts/jquery.js"></script>
    <script type="text/javascript" src="../scripts/jquery-ui.js"></script>
    <script type="text/javascript" src="../scripts/jquery.validate.js"></script>
    
    <script type="text/javascript">
    $(function(){
    //$('#pop_up_form').validate();    
    $("#popup").dialog({ 
    autoOpen: true,
    title : "View/Edit Screen",
    dialogClass : "pop-content pop-header-colr pop-button pop-float",
    width:400,
    height:450,
    modal: true,
    resizable: false,
    show: 'clip',
    buttons:{
    'SUBMIT':function(){
    /*if($('#pop_up_form').valid())
    {
    alert("successfull");
    }*/
    }
    }
    
    });
    
    });
    </script>
    
    </head>
    <body>
    <div id="popup" style="display:none">
    <form action="" name="pop_up_form" id="pop_up_form" method="post"><input class="pop_up_textbox" type="text" name="acct_nmbr" id="acct_nmbr" required maxlength="19" value=""/></form>
    </div> 
    </body>
    </html>

Here if you are un-commenting those jquery code that I commented , you can see that the Jquery validation is working fine. But why HTML5 validation is not working here if I am commenting the Jquery validation code. To test HTML 5 validation I have added an attribute "required" for a form field , but some how this is not working.

I know that for HTML 5 doctype should be " !DOCTYPE HTML". I have added this also but no luck. Is it because of UI dialog box which doesnt support HTML 5 native validation.