diff options
author | Patrick Davison <snapwilliam@gmail.com> | 2013-01-15 01:40:54 -0800 |
---|---|---|
committer | Patrick Davison <snapwilliam@gmail.com> | 2013-01-15 01:40:54 -0800 |
commit | c7d671712a9d5f90752475960c3a602aeb0da8d0 (patch) | |
tree | f912484612e8811b5e7fd52533770942647a769e /pages/chat.php | |
parent | cc579e91af8adbef5ddda979dbbe5db93a8c32ef (diff) | |
download | pathery-c7d671712a9d5f90752475960c3a602aeb0da8d0.tar.xz |
Chat cleanup
Diffstat (limited to 'pages/chat.php')
-rw-r--r-- | pages/chat.php | 40 |
1 files changed, 23 insertions, 17 deletions
diff --git a/pages/chat.php b/pages/chat.php index 11bb935..0096304 100644 --- a/pages/chat.php +++ b/pages/chat.php @@ -49,17 +49,24 @@ topbar($Links); width:330px;
}
+.chatInputMessage {
+ font-family:Comic Sans MS, Comic Sans MS5, cursive;
+ border: 1px solid gray;
+ width: 700px;
+ margin: 4px;
+}
+.chatButton {
+ margin: 4px;
+}
#chatContainer {
- border:1px solid red;
- width:600px;
+ width:800px;
margin:0 auto;
height:400px;
overflow:auto;
}
.chatContainer2 {
- border:1px solid yellow;
- width:610px;
+ width:810px;
margin:0 auto;
height:450px;
overflow:auto;
@@ -89,25 +96,23 @@ function getChatTimer() { getChat();
}
-
-getChat();
function getChatDone(data) {
var items = [];
var p; //our prep string
var newChats = false;
- //console.log('datalength', data.length);
+ ////console.log('datalength', data.length);
if (data.length < 3 || data == 'false')
return;
- console.log("START BUILD");
+ //console.log("START BUILD");
- console.log("JSON TO PARSE", data);
+ //console.log("JSON TO PARSE", data);
json = jQuery.parseJSON(data);
- console.log("JSON PREPED");
+ //console.log("JSON PREPED");
$.each(json, function(key, user) {
@@ -116,7 +121,7 @@ function getChatDone(data) { //var timestamp = postDate.format("ddd h:MM TT");
var timestamp = postDate.format("h:MM:ss");
- console.log("INSIDE BUILD START");
+ //console.log("INSIDE BUILD START");
p = '';
p = p+ " <span class='chatTimestamp'>["+timestamp+"]</span>";
p = p+ " <div class='grid_td' style='float:left; width:35px; height:35px; background:"+user.wallColor+" url(images/marks/"+user.wallEmblem+");'>";
@@ -138,7 +143,7 @@ function getChatDone(data) { newChats = true;
});
- console.log("BUILD DONE");
+ //console.log("BUILD DONE");
if (newChats) {
var new_chatDiv = $('<div/>', {
@@ -148,11 +153,11 @@ function getChatDone(data) { });
new_chatDiv.prependTo('#chatContainer').slideDown('fast');
}
- console.log('(END) lastID', lastID);
+ //console.log('(END) lastID', lastID);
}
function getChat(message) {
- console.log('LASTID:', lastID);
+ //console.log('LASTID:', lastID);
var dataString = 'getChatFromID='+lastID;
if (chatBuffer.length > 0) {
dataString += '&send=true&messages='+chatBuffer.join('|:|');
@@ -198,13 +203,14 @@ function htmlEncode(value){ </script>
-<h3>this page will overflow...</h3>
+<h3>Pathery Chat - BETA</h3>
<div class='chatContainer2'>
<form id='sendChat' onsubmit="return false">
<input type="hidden" name="stuff" value="1724">
- <input type="text" name="message" id="message" value="" maxlength="255" autocomplete="off" >
- <input type="button" class="send" id='chatSendBtn' value='Send' onClick="sendChat();">
+ <input class='chatButton' type="button" class="send" id='chatSendBtn' value='Send' onClick="sendChat();">
+ <input class='chatInputMessage' type="text" name="message" id="message" value="" maxlength="255" autocomplete="off" >
+
</form>
<div id='chatContainer'>
|