Saturday, August 8, 2015

function to validate email Id using Javascript


function to validate email Id using Javascript


function validateEmail(email) {
    var emailReg = new RegExp(/^(("[\w-\s]+")|([\w-]+(?:\.[\w-]+)*)|("[\w-\s]+")([\w-]+(?:\.[\w-]+)*))(@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$)|(@\[?((25[0-5]\.|2[0-4][0-9]\.|1[0-9]{2}\.|[0-9]{1,2}\.))((25[0-5]|2[0-4][0-9]|1[0-9]{2}|[0-9]{1,2})\.){2}(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[0-9]{1,2})\]?$)/i);

    var valid = emailReg.test(email);

    if (!valid) {
        return false;
    } else {
        return true;
    }

}




Saturday, July 25, 2015

get radio button and checkbox value using jquery

How to know checkbox has selected or not using jquery

<input type='checkbox'  id="chkAT">


 var isChecked = $('#chkAT').is(':checked');

     alert(isChecked);


get radiolist selected value :

$('input:radio[name=rdb1]:checked').val();

Convert Html to Pdf in azure function and save in blob container

 In this post  I am going to create an azure function ( httpTrigger ) and send html content  which will be converted into PDF and save in bl...