The toggle() method is used to toggle between show and hide selected
HTML elements. If elements are hidden then toggle method will show
hidden selected elements and vice versa.
Syntax:
Selector = can be an element like div, p, etc.
Speed = Optional parameter that specifies the hide speed with possible values of
Example:
Syntax:
$(selector).toggle(speed,callback)Where
Selector = can be an element like div, p, etc.
Speed = Optional parameter that specifies the hide speed with possible values of
- “slow”
- “fast”
- Or value in milliseconds
Example:
jQuery Testing