Skip to content

Instantly share code, notes, and snippets.

@photofroggy
Created August 18, 2012 05:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save photofroggy/3384561 to your computer and use it in GitHub Desktop.
Save photofroggy/3384561 to your computer and use it in GitHub Desktop.
This is a simple client for dAmn.
<html>
<head>
<title>dAmn Chat</title>
<style type="text/css">
body {
width: auto;
margin: 0;
padding: 0;
height: 97%;
overflow: hidden;
color: #2D506B;
font: normal 12px verdana, sans-serif;
line-height: 1.6em;
background-color: #E7E7E7;
}
nav.crest.chat {
background-color: #406D8B;
height: 25px;
border-bottom: 1px solid #0D4D69;
color: #AFD7F5;
}
nav.crest.chat ul {
margin: 0px;
padding: 0px 5px;
display: inline;
float: left;
list-style: none;
}
nav.crest.chat ul:last-child {
float: right;
}
nav.crest.chat ul li {
display: inline;
}
nav.crest.chat ul li a {
padding-right: 2px;
color: white;
}
div.main {
height: 100%;
width: 100%;
margin-bottom: 0px;
}
a {
color: #334DB3;
text-decoration: none;
}
a:hover { color: #990000 }
a.user em {
font-style: normal;
}
</style>
<link rel="stylesheet" type="text/css" href="https://raw.github.com/photofroggy/wsc/dev/dist/wsc.min.css" />
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>
<script type="text/javascript" src="https://raw.github.com/photofroggy/wsc/dev/dist/wsc.min.js"></script>
<script type="text/javascript">
ns = '#' + ($_GET('ns') || 'devart');
$(function() {
$('.main').wsc( 'init', {
"domain": 'deviantart.com',
"server": 'ws://chat.openflock.com:3902/chat/ws',
'autojoin': ns,
'username': '{username}',
'pk': '{damntoken}',
'stype': 'damn',
'client': 'dAmnClient',
'tablumps': dAmnLumps,
});
$('.main').wsc( 'connect' );
});
</script>
</head>
<body>
<nav class="crest chat">
<ul>
<li>&laquo; <a href="http://deviantart.com/">deviantART</a></li>
</ul>
<ul>
<li>{symbol}<a target="_blank" href="http://{username}.deviantart.com/">{username}</a> &raquo;</li>
</ul>
</nav>
<div class="main">
</div>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment