//Personal Functions Library for the site //jQuery(function ($) { // 'use strict'; // tool tips activation // Function for the data-toggle baloon $(function () { $('[data-toggle="tooltip"]').tooltip() }) // Function to check the strength of the given password function checkPasswordStrength() { //alert("ff"); var number = /([0-9])/; var alphabets = /([a-zA-Z])/; var special_characters = /([~,!,@,#,$,%,^,&,*,-,_,+,=,?,>,<])/; if (!$('#TXT_Pass1').val()) { $('#password-strength-status').html(""); $('#password-strength-status').removeClass(); } else if ($('#TXT_Pass1').val().length < 6) { $('#password-strength-status').removeClass(); $('#password-strength-status').addClass('weak-password small'); $('#password-strength-status').html("Weak (should be atleast 6 characters.)"); } else { if ($('#TXT_Pass1').val().match(number) && $('#TXT_Pass1').val().match(alphabets) && $('#TXT_Pass1').val().match(special_characters)) { $('#password-strength-status').removeClass(); $('#password-strength-status').addClass('strong-password small'); $('#password-strength-status').html("Strong password"); } else { $('#password-strength-status').removeClass(); $('#password-strength-status').addClass('medium-password small'); $('#password-strength-status').html("Medium (should include alphabets, numbers and special characters.)"); } } }; //This function will show hide a password, //Requirement: need the font-awesome 4.7 font icon library //usage, on the text control add this class: G-form-control-pass //and add this line below the text control which will produce the icon // $('.G-form-control-pass-show').click(function () { var id = $(this).siblings('.G-form-control-pass').attr('id'); var fullID = '#' + id //alert(id); if ($(fullID).attr("type") === "text") { $(fullID).attr('type', 'password'); $(this).addClass("ri-eye-off-line"); $(this).removeClass("ri-eye-line"); //alert("text"); } else if ($(fullID).attr("type") === "password") { $(fullID).attr('type', 'text'); $(this).addClass("ri-eye-line"); $(this).removeClass("ri-eye-off-line"); //alert("password"); } }); $('.G-form-control-pass').on('input propertychange', function () { // var mystyle = $(this).G_getInputTypeIconMargin() //alert(mystyle); var $this = $(this); var visible = Boolean($this.val()); $this.siblings('.G-form-control-pass-show').toggleClass('invisible', !visible); }).trigger('propertychange'); $(".G-textarea").each(function () { this.setAttribute("style", "height:" + (this.scrollHeight) + "px;overflow-y:hidden;width:100%"); }).on("input", function () { this.style.height = "auto"; this.style.height = (this.scrollHeight) + "px"; }); // Setup Line for Print of the User Application + Profile ############### var ColLeft = $('#leftCol').height(); var ColRight = $('#RightCol').height(); var lines = (ColLeft - ColRight) / 36; //$('#LBL1').text("the height on left is " + ColLeft + " and on right is " + ColRight + " lines is " + lines); var Slines = "