Skip to content

Commit

Permalink
added the HTML files
Browse files Browse the repository at this point in the history
  • Loading branch information
sirdarckcat authored and borisfaure committed Dec 14, 2009
1 parent e9afd4d commit db546f6
Show file tree
Hide file tree
Showing 8 changed files with 1,718 additions and 0 deletions.
83 changes: 83 additions & 0 deletions amsn2/gui/front_ends/web/html/amsn2.css
@@ -0,0 +1,83 @@

/* Elements that are invisible at the begining */

.login,.contact_list,.mainWindow,.chatWindow,.chatMessage{
display: none;
}

/* general stuff */

/* main elements */

.mainWindow{
padding: 5px;
overflow-y: auto;
}

.login{
}

/* contact_list elements */

.contact_list{
width: 100%;
text-wrap: none;
white-space: nowrap;
overflow-x: hidden;
}
.contact{

}
.groupheader{
background-color: black;
color: white;
cursor: pointer;
}

/* chat widget/window elements */

.chatWindow{
position: absolute;
overflow: hidden;
background-color: white;
padding: 0px;
height: 100%;
width: 100%;
}

.chatWidget{
height: 100%;
width: 100%;
}

.chatWidgetConversation{
overflow-y: auto;
overflow-x: visible;
border: solid 1px black;
height: 70%;
}

.chatMessage{
white-space: pre-wrap;
text-wrap: none;
}

.chatTextInput{
width: 100%;
height: 100%;
}

.chatBottomDiv{
height: 30%;
}

.chatResizeDivContainer{
float: bottom;
cursor: se-resize;
}

.chatResizeDiv{
position: absolute;
bottom: 0px;
right: 0px;
}
32 changes: 32 additions & 0 deletions amsn2/gui/front_ends/web/html/amsn2.html
@@ -0,0 +1,32 @@
<html>
<head>
<title>aMSN2 FrontEnd</title>
<script type="text/javascript">var console={log:function(){}};</script>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="jquery.ui.js"></script>
<link rel="stylesheet" href="jquery-ui-themeroller.css" type="text/css" media="screen">
<style type="text/css">
@import url("amsn2.css");
</style>
<script type="text/javascript" src="backend.js"></script>
</head>
<body>

<div class="splashScreen"></div>

<div class="mainWindow">
<pre class="message">
&nbsp;
</pre>
<div class="login">
Username:<input type="text" id="username"> <br/>
Password:<input type="password" id="password"> <br/>
<input type="button" value="SignIn" id="signin">
</div>
<div class="contact_list">
<div class="title"></div>

</div>
</div>
</body>
</html>
39 changes: 39 additions & 0 deletions amsn2/gui/front_ends/web/html/amsn2.php
@@ -0,0 +1,39 @@
<?php
if(isset($_GET['close'])){
@session_start();
@session_destroy();
}else if (1){
if (isset($_POST['in']) && !empty($_POST['in'])){
$in = fopen("/tmp/test.in","a");
fwrite($in,$_POST['in']);
fclose($in);
echo "//ok".$_POST['in'];
} else
if (isset($_GET['out'])){
@session_start();
if (!isset($_SESSION['index']))
$_SESSION['index']=0;
$index=$_SESSION['index'];
@session_commit();
while (1){
$out = fopen("/tmp/test.out","r");
fseek($out,$index);
$_ = fgets($out);
fclose($out);
if ($_!=""){
$index+=strlen($_);
echo $_;
@session_start();
$_SESSION['index']=$index;
@session_commit();
break;
}else{
sleep(1);
}
}
}else
echo "//wrong operation";
}else{
echo "//service not started";
}
?>

0 comments on commit db546f6

Please sign in to comment.