In this tutorial, we will discuss about how to toggle hide/show by clicking button.
In this tutorial, we will discuss about how to toggle hide/show by clicking button.In this tutorial, we will discuss about how to toggle hide/show by clicking button. In the given below 2 example, there is button ,by clicking on it, the paragraph will hide/show . In first example , the paragraph will hide slowly and also display slowly. While in second paragraph, the paragraph hide/show is instantly, also effect depends on "flip++ % 2 = = 0" equation if it is true ,then it will hide paragraph and if it is false , then it will show paragraph.
jqToggleAppearance1.html
<!DOCTYPE html> |
OUTPUT
After clicking button :
jqToggleAppearance2.html
<!DOCTYPE html> |
OUTPUT
After clicking "Toggle" button :
After again clicking on "Toggle" button :