Posts

Showing posts with the label Code Snippet

Comparing two List to find match in both list, 1st list only, 2nd list only that is Insersect, Minus and Minus Except

Image
In this code snippet post you will learn how to compare two List<T> using lambda expressions. Below code is simple and self-explanatory if you read: Output:

Export table data into excel file

Exporting table data (DOM data) on the HTML page to excel file is a very common requirement. The simplest approach or say the completely client side approach to achieve this is to export the DOM data using client side scripts.

Flip or Rotate Image using CSS

In this quick code you will learn how to flip or rotate image with transition effect using CSS. We will have opportunity to trigger the flip or rotate action on mouse hover or click, for this we will be using jQuery.

Create Expandable or Toggle Drop Down using jQuery

In this quick code you will learn how to create expandable or toggle drop down menu with little icon which shows menu is opened or not. Let's straight look at working example below.

Initialize var with null or empty in C# - learn workarounds

In this quick code you will learn how to initialize var so that it works like null or empty. Technically, this is not possible.

Query string values in JavaScript

Image
In this quick code you will learn how to get query string (browser address bar's variable) values using JavaScript.

Substring in jQuery or using substring(from, to) or substr(start, length) functions

In this quick code you will learn how to get substring from a string in jQuery. A substring is a string which part of another string, we need such functions when some part of string needs to be remove or escape out. We can use either substring(from, to) or substr(start, length) .

Cookies in jQuery with jQuery.Cookie library

Image
In this quick code you will learn how to read, write and delete session cookies using jQuery. Remember to use jquery.cookie library on the page.

Contact Number or Mobile validation in jQuery

In this quick code you will learn how to validate Contact Number or Mobile client side using jQuery. We will be validating only number here because for different countries and providers length may vary. Find the running code below.

Email Validation in jQuery

In this quick code you will learn how to validate Email IDs client side using jQuery. Find the running code below.

Change Button Text using jQuery

I have started sharing "Quick Code Snippet" and this is very first post of the series starting today 27 March 2015.

Popular posts from this blog

Migrating database from ASP.NET Identity to ASP.NET Core Identity

Customize User's Profile in ASP.NET Identity System