<%@ Page Title="Crm Customer Master" Language="C#" MasterPageFile="~/SunMaster.Master" AutoEventWireup="true" EnableEventValidation="false" CodeBehind="CRMCustomerMaster.aspx.cs" Inherits="SUNWEB.CRMCustomerMaster" %>

<%@ Register Assembly="AjaxControlToolkit" TagPrefix="asp" Namespace="AjaxControlToolkit" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">

    <script type="text/javascript" language="javascript">


        $(document).ready(function ()
        {
            var ChkValue = localStorage.getItem("Cvalue");
            if (ChkValue == "C")
            {
                ShowModalIcustomers();
            }

        });


        function exportCustomer(){

        }

        function AllowOnlyNumeric() {
            // Get the ASCII value of the key that the user entered
            var key = window.event.keyCode;

            // Verify if the key entered was a numeric character (0-9) or a decimal (.)
            if ((key > 47 && key < 58) || key == 46)
                // If it was, then allow the entry to continue
                return;

            else
                // If it was not, then dispose the key and continue with entry
                window.event.returnValue = null;
                
            alert("Number Only Allowed")
        }


        function isNumberKey(evt, obj) {
            var charCode = (evt.which) ? evt.which : event.keyCode
            var value = obj.value;
            var dotcontains = value.indexOf(".") != -1;
            if (dotcontains)
                if (charCode == 46) return false;
            if (charCode == 46) return true;
            if (charCode > 31 && (charCode < 48 || charCode > 57))
                return false;
            return true;
        }

        function isNumber(evt) {
            var charCode = evt.which ? evt.which : evt.keyCode;
            // Only digits 0-9
            if (charCode < 48 || charCode > 57) {
                return false;
            }
            return true;
        }


    </script>

    <style type="text/css">
        @media only screen and (max-width: 600px) {
            div {
                text-align: left;
            }
        }
    </style>

    <style type="text/css">
        /* Create two equal columns that floats next to each other */
        .columnLeft {
            float: left;
            width: 50%;
            padding-left: 15px;
            height: auto; /* Should be removed. Only for demonstration */
        }

        .columnRight {
            float: left;
            width: 50%;
            padding-right: 17px;
            height: auto; /* Should be removed. Only for demonstration */
            text-align: right;
            margin-right: -10px;
        }

        /* Clear floats after the columns */
        .row:after {
            content: "";
            display: table;
            clear: both;
        }

        .hrefCss {
            text-decoration: underline;
        }



        .modalCss {
            display: none; /* Hidden by d
                      efault */
            position: fixed; /* Stay in place */
            z-index: 1; /* Sit on top */
            padding-top: 80px; /* Location of the box */
            left: 90px;
            top: 0;
            width: 100%; /* Full width */
            height: 100%; /* Full height */
            overflow: auto; /* Enable scroll if needed */
            background-color: rgb(0,0,0); /* Fallback color */
            background-color: rgba(0,0,0,0.4); /* Black w/ opacity */
        }


        .modal-dialogCss {
        }

        /* Modal Content */
        .modal-contentCss {
            background-color: #fefefe;
            margin: auto;
            /*padding: 20px;*/
            /* border: 1px solid #888;*/
            width: 400px;
            border-radius: 3px;
        }


        /* Create two equal columns that floats next to each other */
        .column 
        {
            float: left;
            width: 40%;
            padding: 2px;
            margin-left: 7px;
            height: auto; /* Should be removed. Only for demonstration */
        }

        /* Clear floats after the columns */
        .row:after {
            content: "";
            display: table;
            clear: both;
        }

        .ButtonSearch {
            background: #ffc108;
            margin: 0;
            font-family: Circular Std Book;
            font-size: 14px;
            line-height: inherit;
            border-width: thin;
            border-color: #212529;
            border-radius: 2px;
            color: #212529;
        }
    </style>

    <script type="text/javascript">

        function refershingpage()
        {
            localStorage.setItem("Cvalue", "C");
            location.href = 'CRMCustomerMaster.aspx';
        }
     
        //Search Members
        function CloseModalMemberInformationList() {
        var modal = document.getElementById("ModalMemberList");
        modal.style.display = "none";
        }


        function ShowModalIcustomers()
        {
            var modal = document.getElementById("ModalMemberList");
            modal.style.display = "block";
            localStorage.removeItem("Cvalue");

        }

        function ShowModalMemberInformationList()
        {
         var modal = document.getElementById("ModalMemberList");
         modal.style.display = "block";
        }

        function CloseModal() {
        var modal = document.getElementById("ModalMemberList");
        modal.style.display = "none";

           
        }

        function ToshowDelButton()
        {
        //var btndel = document.getElementById("btnDelete");
        //btndel.style.display = "block";

        document.getElementById('<%=btnDelete.ClientID%>').style.visibility = 'visible';
           
    }

    </script>

    <script type="text/javascript" language="javascript">
        function validate() {
            //var regex = /^(?=.*[A-Za-z])(?=.*\d)(?=.*[@$!%*#?&])[A-Za-z\d@$!%*#?&]{12,}$/;            
            var regex = /^.{8,}$/;
            if (document.getElementById("<%=txtUserName.ClientID %>").value == "") {
                alert("Enter the UserName");
                document.getElementById("<%=txtUserName.ClientID %>").focus();
                return false;
            }

            if (document.getElementById("<%=txtPassword.ClientID %>").value == "") {
                alert("Enter the Password");
                document.getElementById("<%=txtPassword.ClientID %>").focus();
                return false;
            }

            if(regex.test(document.getElementById("<%=txtPassword.ClientID %>").value) === false){
                //alert("Valid Password should:Minimum 12 characters, at least one letter, one number and one special character");            
                alert("Valid Password should:Minimum 8 characters.");            
                document.getElementById("<%=txtPassword.ClientID %>").focus();
                return false;
            }   
    
           <%-- if (document.getElementById("<%=txtCID.ClientID %>").value == "") {
                alert("Provide CID");
                document.getElementById("<%=txtCID.ClientID %>").focus();
                return false;
            }--%>

            if (document.getElementById("<%=txtDOB.ClientID %>").value == "") {
                alert("Enter the Dob");
                document.getElementById("<%=txtDOB.ClientID %>").focus();
                return false;
            }


            var pin = document.getElementById("<%=txtPIN.ClientID %>").value
            if(pin.length < 6){
                alert("Please Enter Your 6 digit PIN")
                document.getElementById("<%=txtPIN.ClientID %>").focus();
                return false;
            }

       }
    </script>

    <script type="text/javascript" language="javascript">
        function validate1() {
            // var regex = /^(?=.*[A-Za-z])(?=.*\d)(?=.*[@$!%*#?&])[A-Za-z\d@$!%*#?&]{12,}$/;
            var regex = /^.{8,}$/;
            if (document.getElementById("<%=txtUserName.ClientID %>").value == "") {
                alert("Enter the UserName");
                document.getElementById("<%=txtUserName.ClientID %>").focus();
                return false;
            }
             
            <%-- if (document.getElementById("<%=txtCID.ClientID %>").value == "") {
                alert("Provide CID");
                document.getElementById("<%=txtCID.ClientID %>").focus();
                return false;
            }--%>

            if(regex.test(document.getElementById("<%=txtPassword.ClientID %>").value) === false){
                // alert("Valid Password should:Minimum 12 characters, at least one letter, one number and one special character");            
                alert("Valid Password should:Minimum 6 characters."); 
                document.getElementById("<%=txtPassword.ClientID %>").focus();
                return false;
            }   

            if (document.getElementById("<%=txtDOB.ClientID %>").value == "") {
                alert("Enter the Dob");
                document.getElementById("<%=txtDOB.ClientID %>").focus();
                return false;
            }
            
            var pin = document.getElementById("<%=txtPIN.ClientID %>").value
            if(pin.length < 6){
                alert("Please Enter Your 6 digit PIN")
                document.getElementById("<%=txtPIN.ClientID %>").focus();
                return false;
            }
                

        }

    function isNumberKey(evt, obj) {

        var charCode = (evt.which) ? evt.which : event.keyCode
        var value = obj.value;
        var dotcontains = value.indexOf(".") != -1;
        if (dotcontains)
            if (charCode == 46) return false;
        if (charCode == 46) return true;
        if (charCode > 31 && (charCode < 48 || charCode > 57))
            return false;
        return true;
    }




    </script>

</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
   
    <asp:Button ID="btnExcel" runat="server" CssClass="btn btn-success btn-xs" Visible="true"
        OnClick="btnExcel_Click" Text="Export" BackColor="green" BorderColor="green"
        ToolTip="Customer Report" />

   <%--  <div style="font-size:large">
     CRM-MEMBER MASTER 
 </div>--%>

    <asp:UpdatePanel runat="server" ID="updatepanel1" UpdateMode="Conditional">
        <ContentTemplate>
            <%--<table style="width: 100%; padding-bottom: 10px;">
                <tr>
                    <td style="font-size: large; width: 50%; font-family: 'Open Sans', sans-serif; font-weight: bolder;">
                    </td>
                    <td align="right" style="padding-bottom: 0px;">
                        <label for="validationCustom05">
                            Branch
                                <asp:Label ID="lblBranchAliasName" runat="server"></asp:Label>
                        </label>
                        <asp:DropDownList ID="cmbBranches" CssClass="custom-select" runat="server" Width="200px" Height="35px"
                            AutoPostBack="true" OnSelectedIndexChanged="cmbBranches_SelectedIndexChanged">
                        </asp:DropDownList>

                        <div>
                    </td>
                </tr>
            </table>--%>

            <div class="container-fluid">
            <div class="row align-items-center mb-3">
                <div class="col-md-6 col-12">
                    <h6 class="mb-0" style="font-family: 'Open Sans', sans-serif; font-weight: bolder;">
                        CRM-MEMBER MASTER 
                    </h6>
                </div>
                <div class="col-md-6 col-12 text-md-end text-start mt-2 mt-md-0">
                    <label for="cmbBranches" class="form-label me-2">
                        Branch <asp:Label ID="lblBranchAliasName" runat="server"></asp:Label>
                    </label>
                    <asp:DropDownList ID="cmbBranches"
                        CssClass="form-select d-inline-block"
                        Style="width: 200px; height: 35px;"
                        runat="server" AutoPostBack="true"
                        OnSelectedIndexChanged="cmbBranches_SelectedIndexChanged">
                    </asp:DropDownList>
                </div>
            </div>
        </div>



            <h4>&nbsp;<asp:Label ID="lblGreeting" runat="server"></asp:Label></h4>
            <%--<asp:Button ID="btnPdf" runat="server" Text="PDF" 
                    ToolTip="To Export  the Report Click Here"  CssClass="btn btn-secondary" 
                    onclick="btnPdf_Click"/>--%>
            <div>
                <div class="row">
                    <div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
                        <div class="card">
                            <div class="card-body">
                                <h5 class="card-header" style="background-color: #4c4c4c; color: White;">
                                    <%--   <span style="font-size:14px;color:#F8F9FA">MEMBER INFORMATION</span>&nbsp;&nbsp;--%>
                                    <span style="font-size: 14px; color: #F8F9FA">MEMBER INFORMATION </span>&nbsp;&nbsp;
                            <asp:Button ID="btnAddNew" OnClick="btnAddNew_Click" runat="server" class="btn btn-success"  Text="Add New" />

                                    <button type="button" onclick="ShowModalMemberInformationList()" class="btn btn-warning">
                                        Search
                                    </button>

                                    <span style="margin-left: 72%">
                                        <asp:Button ID="btnDelete" runat="server" class="ButtonSearch" BackColor="red" ForeColor="white" Text="Delete" OnClick="btnDelete_Click"
                                            OnClientClick="return confirm(' Are you cofirm to Delete.');" />
                                    </span>
                                </h5>
                                <div class="form-row">
                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <br />
                                        <caption>
                                            <asp:CheckBox ID="chkActive" runat="server" />
                                            <label for="validationCustom03">
                                                Active</label>&nbsp;&nbsp;&nbsp;
                                        </caption>
                                    </div>

                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <br />
                                        <asp:CheckBox ID="chkPDPAStatus" runat="server" />
                                        <label for="validationCustom03">
                                            PDPA</label>&nbsp;&nbsp;&nbsp;
                                          &nbsp;  &nbsp;  &nbsp;&nbsp;  &nbsp;  &nbsp;
                                        &nbsp;  &nbsp;  &nbsp;&nbsp;  &nbsp;  &nbsp;
                                        <asp:CheckBox ID="chkAllowAds" runat="server" />
                                        <label for="validationCustom03">
                                            Allow Marketing</label>&nbsp;&nbsp;&nbsp;
                                    </div>

                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <caption>
                                            <label for="validationCustom03">
                                                Registration Date    
                                            </label>
                                            <asp:TextBox ID="txtDateRegistered" class="form-control" runat="server"></asp:TextBox>
                                            <asp:CalendarExtender ID="CalendarExtender2" Format="yyyy-MM-dd" runat="server" TargetControlID="txtDateRegistered" PopupPosition="BottomLeft" FirstDayOfWeek="Sunday"></asp:CalendarExtender>

                                        </caption>
                                    </div>
                                </div>

                                <div class="form-row">
                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <label for="validationCustom03">
                                            User ID</label>
                                        <asp:TextBox ID="txtUserName" runat="server" class="form-control" onkeypress="return isNumber(event)" MaxLength="8" autocomplete="off"> </asp:TextBox>
                                        
                                    </div>

                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <label for="validationCustom03">
                                            Password</label>
                                        <asp:TextBox ID="txtPassword" runat="server" class="form-control" TextMode="Password" onkeyup="validatepwd(this)"> </asp:TextBox>
                                        <span id="usernameError" style="color:red; font-size:12px;"></span>
                                        <%--<asp:TextBox ID="txtPassword1" runat ="server" Class="form-control" TextMode ="Password" MaxLength ="12" autoComplete ="off"></asp:TextBox>--%>
                                    </div>

                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <label for="validationCustom03">
                                            CID</label>
                                        <asp:TextBox ID="txtCID" runat="server" class="form-control" Enabled="false"> </asp:TextBox>
                                    </div>
                                </div>

                                <div class="form-row">
                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <label style="display: none" for="validationCustom03">
                                            Mobile No</label>
                                        <asp:TextBox ID="txtMobileNo" runat="server" class="form-control" Visible="false"> </asp:TextBox>

                                    </div>
                                </div>

                                <div class="form-row">
                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <label for="validationCustom03">
                                            Customer Name</label>
                                        <asp:TextBox ID="txtCustomerName" runat="server" class="form-control"> </asp:TextBox>
                                    </div>

                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <label for="validationCustom03">
                                            PIN</label>
                                        <asp:TextBox ID="txtPIN" runat="server" TextMode="Password" class="form-control" MaxLength="6" onkeypress="return isNumberKey(event,this)"> </asp:TextBox>

                                    </div>

                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <caption>
                                            <label for="validationCustom03">
                                                DOB    
                                            </label>
                                            <asp:TextBox ID="txtDOB" class="form-control" runat="server"></asp:TextBox>
                                            <asp:CalendarExtender ID="CalendarExtender3" Format="yyyy-MM-dd" runat="server" TargetControlID="txtDOB" PopupPosition="BottomLeft" FirstDayOfWeek="Sunday"></asp:CalendarExtender>

                                        </caption>
                                    </div>

                                    <%--<div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                    <label for="validationCustom03">
                                        Notes</label>
                                    <asp:TextBox ID="txtNotes" runat="server" class="form-control"> </asp:TextBox>
                                </div>--%>

                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <label style="display: none" for="validationCustom03">
                                            Email</label>
                                        <asp:TextBox ID="txtEmail" runat="server" class="form-control" Visible="false"> </asp:TextBox>
                                    </div>

                                </div>

                                <div class="form-row">
                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <label for="validationCustom03">
                                            <asp:Label ID="lblMembershipType" ForeColor="Gray" runat="server" Text="Membership Type"></asp:Label></label>
                                        <asp:DropDownList ID="cmbMembershipType" CssClass="custom-select"
                                            runat="server" AutoPostBack="false" OnSelectedIndexChanged="cmbMembershipType_SelectedIndexChanged">
                                        </asp:DropDownList>
                                    </div>
                                    <div visible="false" class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <label  for="validationCustom03">
                                            Point Expiry Date</label>
                                        <asp:TextBox ID="txtPointExpiryDate" runat="server" class="form-control"> </asp:TextBox>
                                    </div>

                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <label for="validationCustom03">
                                            Notes</label>
                                        <asp:TextBox ID="txtNotes" runat="server" class="form-control"> </asp:TextBox>
                                    </div>

                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <label style="display: none" for="validationCustom03">
                                            Address</label>
                                        <asp:TextBox ID="txtAddress" runat="server" class="form-control" Visible="false"> </asp:TextBox>
                                    </div>

                                    <div visible="false" class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <label style="display: none" for="validationCustom03">
                                            Postal Code</label>
                                        <asp:TextBox ID="txtPostalCode" runat="server" class="form-control" Visible="false"> </asp:TextBox>
                                    </div>

                                </div>

                                <div class="form-row">
                                </div>
                                <div>
                                    <asp:Button ID="btnSave" runat="server" Text="Save"
                                        CssClass="btn btn-primary" OnClick="btnSave_Click" OnClientClick="return validate()" />

                                    <asp:Button ID="btnUpdate" runat="server" Text="Update" OnClientClick="return validate1()"
                                        CssClass="btn btn-primary" OnClick="btnUpdate_Click" />

                                    <asp:Button ID="btnClear" runat="server" Text="Clear"
                                        CssClass="btn btn-primary" OnClick="btnClear_Click" />

                                </div>
                            </div>
                        </div>
                    </div>
                </div>

                <div class="row">
                    <div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
                        <div class="card">
                            <div class="card-body">
                                <h5 class="card-header" style="background-color: #4c4c4c; color: White;">
                                    <%--   <span style="font-size:14px;color:#F8F9FA">MEMBER INFORMATION</span>&nbsp;&nbsp;--%>
                                    <span style="font-size: 14px; color: #F8F9FA">CUSTOMER DATA RETENTION</span>&nbsp;&nbsp;
                                </h5>

                                <div class="form-row  mt-2">
                                    <div class="col-xl-4 col-lg-4 col-md-12 col-sm-12 col-12 mb-2">
                                        <label for="validationCustom03">
                                            <asp:Label ID="Label1" ForeColor="Gray" runat="server" Text="Select Period Year"></asp:Label></label>
                                        <asp:DropDownList ID="cmbYearSelected" CssClass="custom-select" runat="server" AutoPostBack="false">
                                            <asp:ListItem Text="Select" Value="0" />
                                            <asp:ListItem Text="1" Value="1" />
                                            <asp:ListItem Text="2" Value="2" />
                                            <asp:ListItem Text="3" Value="3" />
                                            <asp:ListItem Text="4" Value="4" />
                                            <asp:ListItem Text="5" Value="5" />
                                            <asp:ListItem Text="6" Value="6" />
                                            <asp:ListItem Text="7" Value="7" />
                                        </asp:DropDownList>

                                    </div>
                                </div>
                                <div>
                                    <asp:Button ID="Button1" runat="server" Text="Update"
                                        CssClass="btn btn-primary" OnClick="btnUpdateCDR_Click" />
                                </div>
                            </div>
                        </div>
                    </div>

                </div>

                <div class="modalCss" id="ModalMemberList">
                    <div class="modal-dialogCss" style="width:90%">
                     <%--   <div class="modal-contentCss" >--%>

                        <div class="modal-body">
                            <div class="row">
                                <div class="col-xl-12 col-lg-12 col-md-12 col-sm-12 col-12">
                                    <div class="card">

                                     <h7 class="card-header" style="background-color: #4c4c4c; color: White;">SHOW LIST
                                     <button type="button" class="close" style="color: White; opacity: 1;" onclick="CloseModal()" data-dismiss="modal">
                                        &times;</button>
                                        </h7>
                                        <div class="card-body">
                                           <div class="row">
                                             <div class="column">
                                             <label for="validationCustom03">
                                             Enter User ID
                                             </label>
                                             <asp:TextBox ID="txtUserNameSearch" runat="server" class="form-control" placeholder="Enter UserName" Width="250px">
                                             </asp:TextBox>
                                             </div>
                                             </div>

                                             <div class="row">
                                             <div class="column">
                                             <asp:Button ID="btnMemSearch" runat="server" class="btn btn-primary"
                                             OnClick="btnMemSearch_Click" Text="Apply" />
                                             <asp:Button ID="btnclearPop" Text="Clear" runat="server" OnClientClick="refershingpage()" class="btn btn-primary" />
                                             </div>

                                              </div>
                                              <asp:Label ID="customeridmsg" runat="server" Text="Userid doesn't Exist" ForeColor="Red"></asp:Label>

                                              <br />
                                             <caption>  
                                             <asp:Panel ID="Panel8" runat="server" BackColor="white" Height="550px" ScrollBars="Auto" Width="1200px">
                                             
                                                 <asp:GridView ID="grdMember" runat="server" AutoGenerateColumns="False"
                                                    CssClass="table table-bordered table-striped table-hover"
                                                    DataKeyNames="CustomerID" Font-Size="Small"
                                                    OnSelectedIndexChanged="grdMember_SelectedIndexChanged" Width="100%">
                                                 
                                                    <Columns>
                                                        <asp:TemplateField HeaderText="CustomerID">
                                                            <ItemTemplate>
                                                                <asp:Label ID="lblCustomerID" runat="server" Text='<%#Eval("CustomerID") %>'></asp:Label>
                                                            </ItemTemplate>
                                                        </asp:TemplateField>

                                                        <asp:TemplateField HeaderText="UserName">
                                                            <ItemTemplate>
                                                                <asp:Label ID="lblUserName" runat="server" Text='<%#Eval("UserName") %>'></asp:Label>
                                                            </ItemTemplate>
                                                        </asp:TemplateField>

                                                        <asp:TemplateField HeaderText="CustomerName">
                                                            <ItemTemplate>
                                                                <asp:Label ID="lblCustomerName" runat="server" Text='<%#Eval("CustomerName") %>'></asp:Label>
                                                            </ItemTemplate>
                                                        </asp:TemplateField>

                                                        <asp:ButtonField CommandName="Select" Text="Edit" ItemStyle-ForeColor="Blue" />
                                                    </Columns>

                                                      <HeaderStyle BackColor="white" ForeColor="White" Font-Bold="True" />
                                                    <SelectedRowStyle CssClass="table-primary" />
                                                </asp:GridView>



                                              <br />
                                             </asp:Panel>
                                             </caption>
                                              
                                          </div>
                                         </div>
                                        </div>
                                     </div>
                                    </div>
                                  </div>

                            </div>

                        </div>
      </ContentTemplate>
    </asp:UpdatePanel>
<script>
      function validatepwd(input) {
        var value = input.value;
        var errorLabel = document.getElementById("usernameError");

        if (value.length < 6) {
            errorLabel.innerText = "Password must be at least 6 characters.";
        } else {
            errorLabel.innerText = "";
        }
    }
</script>
<script src="https://code.jquery.com/jquery-3.7.0.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/css/bootstrap.min.css?v=1.1" rel="stylesheet" />
<!-- Bootstrap 5 -->
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css" rel="stylesheet" />
<!-- Optional Bootstrap Icons -->
<link href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.10.5/font/bootstrap-icons.css" rel="stylesheet" />

</asp:Content>


