diff --git a/src/messenger/webim/libs/userinfo.php b/src/messenger/webim/libs/userinfo.php new file mode 100644 index 00000000..df4cb2e0 --- /dev/null +++ b/src/messenger/webim/libs/userinfo.php @@ -0,0 +1,53 @@ + \ No newline at end of file diff --git a/src/messenger/webim/operator/history.php b/src/messenger/webim/operator/history.php index 2689bb9e..fae58114 100644 --- a/src/messenger/webim/operator/history.php +++ b/src/messenger/webim/operator/history.php @@ -15,9 +15,11 @@ require_once('../libs/common.php'); require_once('../libs/operator.php'); require_once('../libs/chat.php'); +require_once('../libs/userinfo.php'); require_once('../libs/pagination.php'); $operator = check_login(); +loadsettings(); $page = array( 'operator' => topage(get_operator_name($operator)) ); $query = isset($_GET['q']) ? myiconv(getoutputenc(), $webim_encoding, $_GET['q']) : false; diff --git a/src/messenger/webim/operator/update.php b/src/messenger/webim/operator/update.php index c0284672..6e63d3fc 100644 --- a/src/messenger/webim/operator/update.php +++ b/src/messenger/webim/operator/update.php @@ -14,6 +14,7 @@ require_once('../libs/common.php'); require_once('../libs/chat.php'); +require_once('../libs/userinfo.php'); require_once('../libs/operator.php'); $operator = get_logged_in(); @@ -39,44 +40,6 @@ $threadstate_key = array( $state_loading => "chat.thread.state_loading" ); -function get_useragent_version($userAgent) { - global $knownAgents; - if (is_array($knownAgents)) { - $userAgent = strtolower($userAgent); - foreach( $knownAgents as $agent ) { - if( strstr($userAgent,$agent) ) { - if( preg_match( "/".$agent."[\\s\/]?(\\d+(\\.\\d+(\\.\\d+(\\.\\d+)?)?)?)/", $userAgent, $matches ) ) { - $ver = $matches[1]; - if($agent=='safari') { - if(preg_match( "/version\/(\\d+(\\.\\d+(\\.\\d+)?)?)/", $userAgent, $matches)) { - $ver = $matches[1]; - } else { - $ver = "1 or 2 (build ".$ver.")"; - } - if(preg_match( "/mobile\/(\\d+(\\.\\d+(\\.\\d+)?)?)/", $userAgent, $matches)) { - $userAgent = "iPhone ".$matches[1]." ($agent $ver)"; - break; - } - } - - $userAgent = ucfirst($agent)." ".$ver; - break; - } - } - } - } - return $userAgent; -} - -function get_user_addr($addr) { - global $settings; - if($settings['geolink'] && preg_match( "/(\\d+\\.\\d+\\.\\d+\\.\\d+)/", $addr, $matches )) { - $userip = $matches[1]; - return get_popup(str_replace("{ip}", $userip, $settings['geolink']), '', htmlspecialchars($addr), "GeoLocation", "ip$userip", $settings['geolinkparams']); - } - return htmlspecialchars($addr); -} - function thread_to_xml($thread,$link) { global $state_chatting, $threadstate_to_string, $threadstate_key, $webim_encoding, $operator, $settings, diff --git a/src/messenger/webim/operator/userhistory.php b/src/messenger/webim/operator/userhistory.php index 4daf3f62..a387c1f0 100644 --- a/src/messenger/webim/operator/userhistory.php +++ b/src/messenger/webim/operator/userhistory.php @@ -15,9 +15,11 @@ require_once('../libs/common.php'); require_once('../libs/operator.php'); require_once('../libs/chat.php'); +require_once('../libs/userinfo.php'); require_once('../libs/pagination.php'); $operator = check_login(); +loadsettings(); $page = array( 'operator' => topage(get_operator_name($operator)) ); diff --git a/src/messenger/webim/view/thread_search.php b/src/messenger/webim/view/thread_search.php index 2def3b75..025c3f6a 100644 --- a/src/messenger/webim/view/thread_search.php +++ b/src/messenger/webim/view/thread_search.php @@ -79,7 +79,7 @@ - + @@ -88,7 +88,7 @@ - , + , diff --git a/src/messenger/webim/view/userhistory.php b/src/messenger/webim/view/userhistory.php index d0a92b78..b6e7174c 100644 --- a/src/messenger/webim/view/userhistory.php +++ b/src/messenger/webim/view/userhistory.php @@ -2,7 +2,7 @@ /* * This file is part of Web Instant Messenger project. * - * Copyright (c) 2005-2008 Web Messenger Community + * Copyright (c) 2005-2009 Web Messenger Community * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -10,209 +10,83 @@ * * Contributors: * Evgeny Gryaznov - initial API and implementation - * - * Ido Green - add more features (base on ID: 2492353) */ ?> - + - + - - - <?php echo getlocal("page.analysis.userhistory.title") ?> - <?php echo getlocal("app.title") ?> - + + + <?php echo getlocal("page.analysis.userhistory.title") ?> - <?php echo getlocal("app.title") ?> + - "> - "> - +"> +"> + - + - - - - - - - - - - - - - - - -
+ + + - + + +
- - - -
-

-
- - - -
- -
-
+
+

+
- -

- - - - - - - - - - + - - - - - - - - - - - - - - - - +

- - + +
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - - - , took: - - - - - More details "; - echo "N/A Flag"; - ?> -
+ + + + + + + + + + + + + + + +
+ + + + + + + , +
+
+ + + +

+
+ + + +
+ -
- - - $first_name"; - ?> -
-
- - - -
-
- -
-
- - - -

- - -
- - - - - - - -
- - - -
-
-
- - - - -
-
- - - - - - - +