-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathchat.html
47 lines (37 loc) · 1.51 KB
/
chat.html
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
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body>
<script type="text/javascript" src="/_ah/channel/jsapi"></script>
<script src="http://code.jquery.com/jquery-1.9.1.js"></script>
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.8.2/jquery.min.js"></script>
<script type="text/javascript" src="js/chat.js"></script>
<link rel="stylesheet" type="text/css" href="css/bootstrap.css">
<link rel="stylesheet" type="text/css" href="css/bootstrap-responsive.css">
<link rel="stylesheet" type="text/css" href="css/preety.css">
<link rel="stylesheet" type="text/css" href="css/media.css">
<script>
channel = new goog.appengine.Channel('{{ token }}');
socket = channel.open();
socket.onopen = onOpen;
socket.onmessage = onMessage;
socket.onerror = function(){};
socket.onclose = function(){};
</script>
<div class = "pageContainer" style = "margin-top:0%">
<div class = "headerContainer"><span class="headerTitle">Chat: <span id="chatwith">{{other}}</span> </span>
</div>
<div id ='displayPlace'>
<div id="nicknameinchat" style = 'display:none'>{{nickname}}</div>
<div>
</div>
</div>
<div class='enterPlace'>
<textarea id='message' style = 'width: 100%;margin: 0 auto'></textarea>
<button class='btn btn-info' id="sendButton" style = 'float:right;'>Send</button>
<a href = "/" class='btn btn-success' id="sendButton" style = 'float:right;'>Home</a>
</div>
</div>
</body>
</html>