Ignore:
Timestamp:
09/12/08 11:41:46 (16 years ago)
Author:
niltonneto
Message:

Vide changelog do módulo.
http://www.expressolivre.org/dev/wiki/jabberit/changelog
Alterações feitas por Alexandre Correia
email: alexandrecorreia@…

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/jabberit_messenger/inc/login.php

    r402 r417  
    11<?php 
     2  /***************************************************************************\ 
     3  *  Expresso - Expresso Messenger                                            * 
     4  *     - Alexandre Correia / Rodrigo Souza                                                               * 
     5  *     - JETI - http://jeti-im.org/                                                                              * 
     6  * ------------------------------------------------------------------------- * 
     7  *  This program is free software; you can redistribute it and/or modify it  * 
     8  *  under the terms of the GNU General Public License as published by the    * 
     9  *  Free Software Foundation; either version 2 of the License, or (at your   * 
     10  *  option) any later version.                                               * 
     11  \***************************************************************************/ 
     12 
     13        define('PHPGW_API_INC','../../phpgwapi/inc'); 
     14        require_once(PHPGW_API_INC . '/class.Template.inc.php'); 
    215 
    316        if(isset($_SESSION['phpgw_info']['jabberit_messenger']['name_jabberit'])) 
    417    { 
    518                $path = $_SESSION['phpgw_info']['jabberit_messenger']['webserver_url']; 
     19                $SERVER_EXPRESSO = gethostbyaddr($_SERVER['SERVER_ADDR']) . $path; 
    620 
    7                 $newWindow = "<script type='text/javascript'>"; 
    8                 $newWindow .= "document.write('<HTML>');";  
    9                 $newWindow .= "document.write('<HEAD>');"; 
    10                 $newWindow .= "document.write('</HEAD>');"; 
    11                 $newWindow .= "document.write('<BODY leftmargin=\'0\' topmargin=\'0\' marginwidth=\'0\' marginheight=\'0\'>');"; 
    12                 $newWindow .= "document.write('<APPLET name=\'jeti\' "; 
    13                 $newWindow .= "archive=\'".$path."applet.jar,"; 
    14                 $newWindow .= $path."plugins/groupchat.jar,"; 
    15                 $newWindow .= $path."plugins/sound.jar,"; 
    16                 $newWindow .= $path."plugins/xhtml.jar\' CODE=\'nu.fw.jeti.applet.Jeti.class\' WIDTH=\'100%\' HEIGHT=\'400px\'>');"; 
    17                 $newWindow .= "document.write('<PARAM NAME=\"SERVER\" VALUE=\'".$_SESSION['phpgw_info']['jabberit_messenger']['name_jabberit']."\'>');"; 
    18                 $newWindow .= "document.write('<PARAM NAME=\"HOST\" VALUE=\'".$_SESSION['phpgw_info']['jabberit_messenger']['name_jabberit']."\'>');"; 
    19                 $newWindow .= "document.write('<PARAM NAME=\"PORT\" VALUE=\'".$_SESSION['phpgw_info']['jabberit_messenger']['port_jabberit']."\'>');"; 
    20                 $newWindow .= "document.write('<PARAM NAME=\"RESOURCE\" VALUE=\'".$_SESSION['phpgw_info']['jabberit_messenger']['resource_jabberit']."\'>');"; 
    21                 $newWindow .= "document.write('<PARAM NAME=\"USER\" VALUE=\'".$_SESSION['phpgw_info']['jabberit_messenger']['user']."\'>');"; 
    22                 $newWindow .= "document.write('<PARAM NAME=\"PASSWORD\" VALUE=\'".$_SESSION['phpgw_info']['jabberit_messenger']['passwd']."\'>');"; 
    23                 $newWindow .= "document.write('<PARAM NAME=\"SSL\" VALUE=\'".$_SESSION['phpgw_info']['jabberit_messenger']['use_ssl_jabberit']."\'>');"; 
    24                 $newWindow .= "document.write('<PARAM NAME=\"HIDELOGINSTATUS\" VALUE=\"TRUE\">');"; 
    25                 //$newWindow .= "document.write('<PARAM NAME=\"USEPROXY\" VALUE=\'".strtoupper($_SESSION['phpgw_info']['jabberit_messenger']['use_proxy_java'])."\'>');"; 
    26                 $newWindow .= "document.write('<PARAM NAME=\"EXTIPAGE\" VALUE=\"javascript:window.close();\">');"; 
    27                 $newWindow .= "document.write('</APPLET>');"; 
    28                 $newWindow .= "document.write('</BODY>');"; 
    29                 $newWindow .= "document.write('</HTML>');"; 
    30                 $newWindow .= "document.close();"; 
    31                 $newWindow .= "</script>"; 
     21                $template = new Template('templates/celepar'); 
     22                $template->set_var("path", $path); 
     23                $template->set_var("file0", filemtime("applet.jar")); 
     24                $template->set_var("file1", filemtime("plugins/groupchat.jar")); 
     25                $template->set_var("file2", filemtime("plugins/sound.jar")); 
     26                $template->set_var("file3", filemtime("plugins/xhtml.jar"));             
     27                $template->set_var("value_server",$_SESSION['phpgw_info']['jabberit_messenger']['name_jabberit']); 
     28                $template->set_var("value_host",$_SESSION['phpgw_info']['jabberit_messenger']['name_jabberit']);                         
     29                $template->set_var("value_port",$_SESSION['phpgw_info']['jabberit_messenger']['port_jabberit']); 
     30                $template->set_var("value_resource",$_SESSION['phpgw_info']['jabberit_messenger']['resource_jabberit']); 
     31                $template->set_var("value_user",$_SESSION['phpgw_info']['jabberit_messenger']['user']); 
     32                $template->set_var("value_password",$_SESSION['phpgw_info']['jabberit_messenger']['passwd']); 
     33                $template->set_var("value_ssl",$_SESSION['phpgw_info']['jabberit_messenger']['use_ssl_jabberit']); 
     34                $template->set_var("value_hideloginstatus","TRUE"); 
     35                $template->set_var("value_userproxy",$_SESSION['phpgw_info']['jabberit_messenger']['use_proxy_java']); 
     36                $template->set_var("value_expresso",$SERVER_EXPRESSO); 
     37                $template->set_file(Array('jabberit_messenger' => 'jabberIM.tpl')); 
     38                $template->set_block('jabberit_messenger','index'); 
     39                $template->pfp('out','index'); 
     40    } 
    3241 
    33                 printf("%s",$newWindow); 
    34         } 
    3542?> 
Note: See TracChangeset for help on using the changeset viewer.