On click, replace the button with a div containing the same word.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
|
Демонстрация:
Replace all paragraphs with bold words.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
|
Демонстрация:
On click, replace each paragraph with a div that is already in the DOM and selected with the $()
function. Notice it doesn't clone the object but rather moves it to replace the paragraph.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
|
Демонстрация:
On button click, replace the containing div with its child divs and append the class name of the selected element to the paragraph.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
|