-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.js
66 lines (59 loc) · 1.81 KB
/
index.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
62
63
64
65
66
/**
* Created by vshivakumar on 9/24/15.
*/
$(document).ready(function(){
//alert('hello');
//$("#header").load("/cse392/header.html");
$.get("header.html", function( data ) {
$("#header").html( data );
//alert( "Ok. Load." );
});
$('.sidebar-item').mouseenter(function(){
$(this).css('z-index', 9);
$(this).animate({
width: 135,
height: 135
}, 150, function() {
// Animation complete.
});
});
$('.sidebar-item').mouseleave(function(){
$(this).css('z-index', 1);
$(this).animate({
width: 125,
height: 125
}, 150, function() {
// Animation complete.
});
});
$('#wave-animation').animate({
right: '-=1000%'
}, 250000, 'linear', function () {
ocean();
});
$('#submit-btn').click(function(){
// delete window.alert;
// alert("Message Submitted! Thank You!");
//$('#message-status').innerHTML("");
//$('#message-status').innerHTML("Message Submitted! Thank You!");
});
// Set the picture to be a perfect circle
var picture = $('#picture');
picture.css("height", picture.css("width"));
function postContactToGoogle(){
alert("hello");
var name = $('#name').value();
var message = $('#message').value();
if (name !== "") {
$.ajax({ url: "https://docs.google.com/forms/d/1-9ot14C9_ycZadWJJMieKKDPzXy83f-adaahMkdV0aE/formResponse",
data: {"entry.1010706963" : name, "entry.1673841111" : message },
type: "POST",
dataType: "xml",
statusCode: {
0: function (){alert("Success 0!")},
200: function (){alert("Success 200!")}
}
});
} else { /*Error message*/ }
}
});