回答編集履歴
1
情報の追加。
test
CHANGED
@@ -21,3 +21,37 @@
|
|
21
21
|
} );
|
22
22
|
|
23
23
|
```**動くサンプル:**[https://jsfiddle.net/s6be2LL6/](https://jsfiddle.net/s6be2LL6/)
|
24
|
+
|
25
|
+
|
26
|
+
|
27
|
+
---
|
28
|
+
|
29
|
+
|
30
|
+
|
31
|
+
**追記:**
|
32
|
+
|
33
|
+
|
34
|
+
|
35
|
+
```JavaScript
|
36
|
+
|
37
|
+
$( function() {
|
38
|
+
|
39
|
+
var html = '', img_count = 10, i = 0;
|
40
|
+
|
41
|
+
while( i < img_count ) {
|
42
|
+
|
43
|
+
++i;
|
44
|
+
|
45
|
+
html += '<a href="https://placehold.jp/24/99cc99/339933/350x150.png?text='+ i + '.jpg">';
|
46
|
+
|
47
|
+
html += '<img src="https://placehold.jp/24/cc9999/993333/150x50.png?text='+ i + '.jpg">';
|
48
|
+
|
49
|
+
html += '</a>';
|
50
|
+
|
51
|
+
}
|
52
|
+
|
53
|
+
$( 'body' ).html( html );
|
54
|
+
|
55
|
+
} );
|
56
|
+
|
57
|
+
```**動くサンプル:**[https://jsfiddle.net/s6be2LL6/2/](https://jsfiddle.net/s6be2LL6/2/)
|