forked from codeforamerica/hnl-social-media-handbook
-
Notifications
You must be signed in to change notification settings - Fork 2
/
app.js
61 lines (40 loc) · 1.09 KB
/
app.js
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
$(document).ready(function() {
var show_application = function(){
$("#information").hide();
$("#application").show();
window.scrollTo(0,500);
}
$("#application").hide();
$(".Apply .button").live( 'click', function() {
show_application();
window.location.hash = '#application';
//Firefox for some reason does not refresh the DOM in iFrame
if($.browser.mozilla){
document.getElementsByTagName('iframe')[0].src=document.getElementsByTagName('iframe')[0].src
}
});
$("div#application a.back").click(function() {
$("#application").hide();
$("#information").show();
window.location.hash = '';
});
$('.advisorimages ul li img').popover({
placement: 'bottom',
animation: false}
);
// anchor scrolling
var didScroll = true;
var sections = $(".wrapper").each(function(index) {
$(this).data("height", $(this).height());
});
var links = $(".subnav a");
$(".subnav").localScroll({
axis : "y",
duration : 1000,
easing : "easeInOutExpo",
hash : true
});
if(window.location.hash == '#application'){
show_application();
}
});;