質問編集履歴
2
コードブロックで囲んでいなかったコードを削除しました。
test
CHANGED
File without changes
|
test
CHANGED
@@ -38,108 +38,70 @@
|
|
38
38
|
|
39
39
|
|
40
40
|
|
41
|
+
```ここに言語を入力
|
42
|
+
|
43
|
+
$(function() {
|
44
|
+
|
45
|
+
var pageTop = $('.page-top');
|
46
|
+
|
47
|
+
pageTop.hide();
|
48
|
+
|
49
|
+
$(window).scroll(function () {
|
50
|
+
|
51
|
+
if ($(this).scrollTop() > 600) {
|
52
|
+
|
53
|
+
pageTop.fadeIn();
|
54
|
+
|
55
|
+
} else {
|
56
|
+
|
57
|
+
pageTop.fadeOut();
|
58
|
+
|
59
|
+
}
|
60
|
+
|
61
|
+
});
|
62
|
+
|
63
|
+
pageTop.click(function () {
|
64
|
+
|
65
|
+
$('body, html').animate({scrollTop:0}, 500, 'swing');
|
66
|
+
|
67
|
+
return false;
|
68
|
+
|
69
|
+
});
|
70
|
+
|
71
|
+
});
|
72
|
+
|
73
|
+
|
74
|
+
|
75
|
+
});
|
76
|
+
|
77
|
+
// Preloder script
|
78
|
+
|
41
|
-
jQuery(function(
|
79
|
+
jQuery(window).load(function(){'use strict';
|
80
|
+
|
42
|
-
|
81
|
+
$(".preloader").delay(1600).fadeOut("slow").remove();
|
82
|
+
|
43
|
-
|
83
|
+
});
|
44
|
-
|
84
|
+
|
45
|
-
|
85
|
+
//Preloder script
|
86
|
+
|
46
|
-
|
87
|
+
jQuery(window).load(function(){'use strict';
|
88
|
+
|
89
|
+
|
90
|
+
|
91
|
+
// Slider Height
|
92
|
+
|
93
|
+
var slideHeight = $(window).height();
|
94
|
+
|
95
|
+
$('#home .carousel-inner .item, #home .video-container').css('height',slideHeight);
|
96
|
+
|
97
|
+
|
98
|
+
|
47
|
-
$(window).
|
99
|
+
$(window).resize(function(){'use strict',
|
48
|
-
|
100
|
+
|
49
|
-
$(
|
101
|
+
$('#home .carousel-inner .item, #home .video-container').css('height',slideHeight);
|
50
|
-
|
51
|
-
$("#parador").parallax("50%", 0.3);
|
52
102
|
|
53
103
|
});
|
54
104
|
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
// Navigation Scroll
|
60
|
-
|
61
|
-
$(window).scroll(function(event) {
|
62
|
-
|
63
|
-
Scroll();
|
64
|
-
|
65
|
-
});
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
$('.navbar-collapse ul li a').click(function() {
|
70
|
-
|
71
|
-
$('html, body').animate({scrollTop: $(this.hash).offset().top - 79}, 1000);
|
72
|
-
|
73
|
-
return false;
|
74
|
-
|
75
|
-
});
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
```ここに言語を入力
|
80
|
-
|
81
|
-
$(function() {
|
82
|
-
|
83
|
-
var pageTop = $('.page-top');
|
84
|
-
|
85
|
-
pageTop.hide();
|
86
|
-
|
87
|
-
$(window).scroll(function () {
|
88
|
-
|
89
|
-
if ($(this).scrollTop() > 600) {
|
90
|
-
|
91
|
-
pageTop.fadeIn();
|
92
|
-
|
93
|
-
} else {
|
94
|
-
|
95
|
-
pageTop.fadeOut();
|
96
|
-
|
97
|
-
}
|
98
|
-
|
99
|
-
});
|
100
|
-
|
101
|
-
pageTop.click(function () {
|
102
|
-
|
103
|
-
$('body, html').animate({scrollTop:0}, 500, 'swing');
|
104
|
-
|
105
|
-
return false;
|
106
|
-
|
107
|
-
});
|
108
|
-
|
109
|
-
});
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
});
|
114
|
-
|
115
|
-
// Preloder script
|
116
|
-
|
117
|
-
jQuery(window).load(function(){'use strict';
|
118
|
-
|
119
|
-
$(".preloader").delay(1600).fadeOut("slow").remove();
|
120
|
-
|
121
|
-
});
|
122
|
-
|
123
|
-
//Preloder script
|
124
|
-
|
125
|
-
jQuery(window).load(function(){'use strict';
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
// Slider Height
|
130
|
-
|
131
|
-
var slideHeight = $(window).height();
|
132
|
-
|
133
|
-
$('#home .carousel-inner .item, #home .video-container').css('height',slideHeight);
|
134
|
-
|
135
|
-
|
136
|
-
|
137
|
-
$(window).resize(function(){'use strict',
|
138
|
-
|
139
|
-
$('#home .carousel-inner .item, #home .video-container').css('height',slideHeight);
|
140
|
-
|
141
|
-
});
|
142
|
-
|
143
105
|
});
|
144
106
|
|
145
107
|
|
1
コードブロックで囲みました。
test
CHANGED
File without changes
|
test
CHANGED
@@ -12,6 +12,8 @@
|
|
12
12
|
|
13
13
|
|
14
14
|
|
15
|
+
```ここに言語を入力
|
16
|
+
|
15
17
|
Uncaught TypeError: Cannot read property 'top' of undefined
|
16
18
|
|
17
19
|
at HTMLAnchorElement.<anonymous> (main.js:61)
|
@@ -28,12 +30,122 @@
|
|
28
30
|
|
29
31
|
at v.handle (jquery.js:5)
|
30
32
|
|
33
|
+
```
|
34
|
+
|
31
35
|
|
32
36
|
|
33
37
|
###該当のソースコード
|
34
38
|
|
35
39
|
|
36
40
|
|
41
|
+
jQuery(function($) {'use strict',
|
42
|
+
|
43
|
+
|
44
|
+
|
45
|
+
// all Parallax Section
|
46
|
+
|
47
|
+
$(window).load(function(){'use strict',
|
48
|
+
|
49
|
+
$("#services").parallax("50%", 0.3);
|
50
|
+
|
51
|
+
$("#parador").parallax("50%", 0.3);
|
52
|
+
|
53
|
+
});
|
54
|
+
|
55
|
+
|
56
|
+
|
57
|
+
|
58
|
+
|
59
|
+
// Navigation Scroll
|
60
|
+
|
61
|
+
$(window).scroll(function(event) {
|
62
|
+
|
63
|
+
Scroll();
|
64
|
+
|
65
|
+
});
|
66
|
+
|
67
|
+
|
68
|
+
|
69
|
+
$('.navbar-collapse ul li a').click(function() {
|
70
|
+
|
71
|
+
$('html, body').animate({scrollTop: $(this.hash).offset().top - 79}, 1000);
|
72
|
+
|
73
|
+
return false;
|
74
|
+
|
75
|
+
});
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
```ここに言語を入力
|
80
|
+
|
81
|
+
$(function() {
|
82
|
+
|
83
|
+
var pageTop = $('.page-top');
|
84
|
+
|
85
|
+
pageTop.hide();
|
86
|
+
|
87
|
+
$(window).scroll(function () {
|
88
|
+
|
89
|
+
if ($(this).scrollTop() > 600) {
|
90
|
+
|
91
|
+
pageTop.fadeIn();
|
92
|
+
|
93
|
+
} else {
|
94
|
+
|
95
|
+
pageTop.fadeOut();
|
96
|
+
|
97
|
+
}
|
98
|
+
|
99
|
+
});
|
100
|
+
|
101
|
+
pageTop.click(function () {
|
102
|
+
|
103
|
+
$('body, html').animate({scrollTop:0}, 500, 'swing');
|
104
|
+
|
105
|
+
return false;
|
106
|
+
|
107
|
+
});
|
108
|
+
|
109
|
+
});
|
110
|
+
|
111
|
+
|
112
|
+
|
113
|
+
});
|
114
|
+
|
115
|
+
// Preloder script
|
116
|
+
|
117
|
+
jQuery(window).load(function(){'use strict';
|
118
|
+
|
119
|
+
$(".preloader").delay(1600).fadeOut("slow").remove();
|
120
|
+
|
121
|
+
});
|
122
|
+
|
123
|
+
//Preloder script
|
124
|
+
|
125
|
+
jQuery(window).load(function(){'use strict';
|
126
|
+
|
127
|
+
|
128
|
+
|
129
|
+
// Slider Height
|
130
|
+
|
131
|
+
var slideHeight = $(window).height();
|
132
|
+
|
133
|
+
$('#home .carousel-inner .item, #home .video-container').css('height',slideHeight);
|
134
|
+
|
135
|
+
|
136
|
+
|
137
|
+
$(window).resize(function(){'use strict',
|
138
|
+
|
139
|
+
$('#home .carousel-inner .item, #home .video-container').css('height',slideHeight);
|
140
|
+
|
141
|
+
});
|
142
|
+
|
143
|
+
});
|
144
|
+
|
145
|
+
|
146
|
+
|
147
|
+
// User define function
|
148
|
+
|
37
149
|
function Scroll() {
|
38
150
|
|
39
151
|
var contentTop = [];
|
@@ -70,7 +182,125 @@
|
|
70
182
|
|
71
183
|
};
|
72
184
|
|
73
|
-
|
185
|
+
```
|
186
|
+
|
187
|
+
|
188
|
+
|
189
|
+
《CSS》
|
190
|
+
|
191
|
+
|
192
|
+
|
193
|
+
```ここに言語を入力
|
194
|
+
|
195
|
+
.page-top {
|
196
|
+
|
197
|
+
position: fixed;
|
198
|
+
|
199
|
+
bottom: 20px;
|
200
|
+
|
201
|
+
right: 20px;
|
202
|
+
|
203
|
+
font-size: 77%;
|
204
|
+
|
205
|
+
}
|
206
|
+
|
207
|
+
.page-top a {
|
208
|
+
|
209
|
+
background: #666;
|
210
|
+
|
211
|
+
text-decoration: none;
|
212
|
+
|
213
|
+
color: #fff;
|
214
|
+
|
215
|
+
width: 100px;
|
216
|
+
|
217
|
+
padding: 30px 0;
|
218
|
+
|
219
|
+
text-align: center;
|
220
|
+
|
221
|
+
display: block;
|
222
|
+
|
223
|
+
border-radius: 5px;
|
224
|
+
|
225
|
+
}
|
226
|
+
|
227
|
+
.page-top a:hover {
|
228
|
+
|
229
|
+
text-decoration: none;
|
230
|
+
|
231
|
+
background: #999;
|
232
|
+
|
233
|
+
}
|
234
|
+
|
235
|
+
```
|
236
|
+
|
237
|
+
|
238
|
+
|
239
|
+
《HTML》
|
240
|
+
|
241
|
+
|
242
|
+
|
243
|
+
```ここに言語を入力
|
244
|
+
|
245
|
+
<body id="top">
|
246
|
+
|
247
|
+
<div class="preloader">
|
248
|
+
|
249
|
+
<div class="preloder-wrap">
|
250
|
+
|
251
|
+
<div class="preloder-inner">
|
252
|
+
|
253
|
+
<div class="ball"></div>
|
254
|
+
|
255
|
+
<div class="ball"></div>
|
256
|
+
|
257
|
+
<div class="ball"></div>
|
258
|
+
|
259
|
+
<div class="ball"></div>
|
260
|
+
|
261
|
+
<div class="ball"></div>
|
262
|
+
|
263
|
+
<div class="ball"></div>
|
264
|
+
|
265
|
+
<div class="ball"></div>
|
266
|
+
|
267
|
+
</div>
|
268
|
+
|
269
|
+
</div>
|
270
|
+
|
271
|
+
</div><!--/.preloader-->
|
272
|
+
|
273
|
+
<header id="navigation">
|
274
|
+
|
275
|
+
<div class="navbar navbar-inverse navbar-fixed-top" role="banner">
|
276
|
+
|
277
|
+
<div class="container">
|
278
|
+
|
279
|
+
<div class="navbar-header">
|
280
|
+
|
281
|
+
|
282
|
+
|
283
|
+
|
284
|
+
|
285
|
+
---------- 中略 ----------
|
286
|
+
|
287
|
+
|
288
|
+
|
289
|
+
|
290
|
+
|
291
|
+
</footer> <!--/#footer-->
|
292
|
+
|
293
|
+
<a href="#home" class="page-top"><i class="fa fa-chevron-up" aria-hidden="true"></i><br>PAGE TOP</a>
|
294
|
+
|
295
|
+
|
296
|
+
|
297
|
+
|
298
|
+
|
299
|
+
</body>
|
300
|
+
|
301
|
+
</html>
|
302
|
+
|
303
|
+
```
|
74
304
|
|
75
305
|
|
76
306
|
|