Show hide div using jQuery in

In this article, we will discuss how we can show or hide a div using jQuery in our application.
You can also check my previous posts on:
First we have to give reference to the jQuery library like below:
<script type=”text/javascript” src=””></script>
Then we need to write the function. Below is the full .aspx code.
.aspx code: 
<%@ Page Language=”C#” AutoEventWireup=”true” CodeFile=”ShowHideDiv.aspx.cs” Inherits=”ShowHideDiv” %>
<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN” “”>
<html xmlns=””>
<head runat=”server”>
<script type=”text/javascript” src=””></script>
<title>Show hide div using jQuery</title>
<script type=”text/javascript”>
$(document).ready(function (){
$(‘.show_hide’).click(function () {
<form id=”form1″ runat=”server”>
<div><a href=”#” class=”show_hide”>Show/hide</a>
<div class=”mydiv”>This div will behave like show or hide !!!</div>
Check out Best Alternative to InfoPath -> Try Now

You May Also like the Following SharePoint Online Tutorials:

About Bijay Kumar

I am Bijay from Odisha, India. Currently working in my own venture TSInfo Technologies in Bangalore, India. I am Microsoft Office Servers and Services (SharePoint) MVP (5 times). I works in SharePoint 2016/2013/2010, SharePoint Online Office 365 etc. Check out My MVP Profile.. I also run popular SharePoint web site

View all posts by Bijay Kumar →