<?

/************************************************************************/
/* XChat Version 0.9.8                                                  */
/* ==================================================================== */
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 of the License.       */
/************************************************************************/

?>
<html>
<head>
<link rel="stylesheet" href="main.css" type="text/css">
<style>
<!--
BODY {
  font-family: Verdana, sans-serif;
  color: #000055;
  font-size: 12px;
  font-weight: normal;
}
-->
</style>
<SCRIPT LANGUAGE="JavaScript">
<!--
scrolling=true;
function moves(){
    if(scrolling != false) {
      window.scroll(1,5000000);
    }
    window.setTimeout("moves()",100);
}
moves();

function newImage(arg) {
        if (document.images) {
                rslt = new Image();
                rslt.src = arg;
                return rslt;
        }
}

function changeImages() {
        if (document.images && (preloadFlag == true)) {
                for (var i=0; i<changeImages.arguments.length; i+=2) {
                        document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
                }
        }
}

var preloadFlag = false;
function preloadImages() {
        if (document.images) {
    useron      = newImage("images/u3.gif");
    useroff     = newImage("images/u4.gif");
    sound       = newImage("images/beep.gif");
<?
  require("./inc/config.php");
  require("./inc/mysql.lib.php");

  $DbSmiles = new DB($dbhost, $dbname, $dbuname, $dbpass);
  $DbSmiles->query("SELECT code, file, emotion FROM ".$prefix."_4nchatsmile");
  if($DbSmiles->num_rows() > 0) {
    while(list($code, $filename, $emotion, $length) = $DbSmiles->next_record()) {
      $emotion = strtr($emotion, " ", "_");
      echo "    ".$emotion." = newImage(\"".$smilesdir."/".$filename."\");\n";
    }
  }
  $DbSmiles->clean_results();
  $DbSmiles->close();
?>
                preloadFlag = true;
        }
}
// -->
</script>
</head>
<body bgcolor="#ffffff" onLoad="preloadImages()" onMouseOver="scrolling=false" onMouseOut="scrolling=true" marginwidth="0" marginheight="0" leftmargin="3" rightmargin="10" topmargin="3">