-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathscripts.js
More file actions
40 lines (34 loc) · 880 Bytes
/
scripts.js
File metadata and controls
40 lines (34 loc) · 880 Bytes
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
39
40
$(document).ready(function() {
//On load, hide everything but the Home page.
$('#about').hide();
$('#portfolio').hide();
$('#contact').hide();
//Home page
$("#navHome").on("click", function(){
$('#home').hide().fadeIn(1000);
$('#about').hide();
$('#portfolio').hide();
$('#contact').hide();
});
//About page
$("#navAbout").on("click", function(){
$('#home').hide();
$('#about').hide().fadeIn(1000);
$('#portfolio').hide();
$('#contact').hide();
});
//Portfolio page
$("#navPortfolio").on("click", function(){
$('#home').hide();
$('#about').hide();
$('#portfolio').hide().fadeIn(1000);
$('#contact').hide();
});
//Contact page
$("#navContact").on("click", function(){
$('#home').hide();
$('#about').hide();
$('#portfolio').hide();
$('#contact').hide().fadeIn(1000);
});
});