Codelab Editor
Free Online HTML Editor
Run
Learn jQuery
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>jQuery Chaining – Simple Chain</title> <script src="https://code.jquery.com/jquery-3.7.1.min.js"></script> <style> body { font-family: Arial, sans-serif; padding: 2rem; background: #f9fafb; } h3 { color: #4a5568; } #chain-demo { width: 150px; height: 150px; background: #a0aec0; color: white; line-height: 150px; text-align: center; margin-bottom: 1rem; border-radius: 4px; position: relative; } #startChain { padding: 0.5rem 1rem; background: #2b6cb0; color: white; border: none; border-radius: 4px; cursor: pointer; } #startChain:hover { background: #2c5282; } </style> </head> <body> <h3>Simple Chain</h3> <p>This example demonstrates how to chain multiple jQuery methods—CSS changes and effects—in a single statement for concise, sequential animations.</p> <div id="chain-demo">Chain Demo</div> <button id="startChain">Run Chain</button> <script> $('#startChain').click(function(){ $('#chain-demo') .css('background', '#f6ad55') .slideUp(500) .slideDown(500) .fadeOut(500) .fadeIn(500); }); </script> </body> </html>
Editor Commands
Ctrl
F
Find
Ctrl
G
Find Next
Ctrl
⇧
G
Find Previous
Ctrl
⇧
F
Find & Replace
Ctrl
]
Indent Code Right
Ctrl
[
Indent Code Left
⇧
Tab
Auto Indent Code
Ctrl
/
Line Comment
Ctrl
Alt
/
Block Comment
TutsInsider Actions
Alt
S
Run Code
Ctrl
C
Copy Editor Code
Ctrl
A
Select All Editor Code
Ctrl
S
Save/Download
Ctrl
Alt
X
Rotate
Ctrl
Alt
T
Switch Theme
Ctrl
⇧
C
Open Console
Esc
Close Console