Commit 182ef4adb126af902745840d53ad0e4138265d52
Merge branch 'edge' of git@github.com:ktgit/knowledgetree into edge
Showing
5 changed files
with
134 additions
and
97 deletions
webservice/clienttools/clienttools_syslog.php
| @@ -7,6 +7,12 @@ class Clienttools_Syslog{ | @@ -7,6 +7,12 @@ class Clienttools_Syslog{ | ||
| 7 | private static $errorLogTemplate='[date] | [time] | ERROR | [session] | [user] | [location] | [error_detail] | ([error])'; | 7 | private static $errorLogTemplate='[date] | [time] | ERROR | [session] | [user] | [location] | [error_detail] | ([error])'; |
| 8 | 8 | ||
| 9 | 9 | ||
| 10 | + /** | ||
| 11 | + * Parse an array into a string template | ||
| 12 | + * @param $template The template string - array keys in square brackets : [date] | [time] | ERROR | [session] | [user] | [location] | [error_detail] | ([error]) | ||
| 13 | + * @param $data The associative array to parse into template. Keys will replace [keys] in template string. | ||
| 14 | + * @return string The parsed template string | ||
| 15 | + */ | ||
| 10 | private static function parseTemplate($template=NULL,$data=NULL){ | 16 | private static function parseTemplate($template=NULL,$data=NULL){ |
| 11 | $ret=null; | 17 | $ret=null; |
| 12 | if(is_array($data)){ | 18 | if(is_array($data)){ |
| @@ -17,7 +23,6 @@ class Clienttools_Syslog{ | @@ -17,7 +23,6 @@ class Clienttools_Syslog{ | ||
| 17 | $txd=array_values($data); | 23 | $txd=array_values($data); |
| 18 | $ret=str_replace($txs,$txd,$template); | 24 | $ret=str_replace($txs,$txd,$template); |
| 19 | }; | 25 | }; |
| 20 | -// echo print_r(Array('s'=>$txs,'d'=>$txd),true)."\n\n\n\n\n\n"; | ||
| 21 | return $ret; | 26 | return $ret; |
| 22 | } | 27 | } |
| 23 | 28 | ||
| @@ -32,8 +37,12 @@ class Clienttools_Syslog{ | @@ -32,8 +37,12 @@ class Clienttools_Syslog{ | ||
| 32 | } | 37 | } |
| 33 | 38 | ||
| 34 | 39 | ||
| 40 | + /** | ||
| 41 | + * Write a line to the log file. | ||
| 42 | + * @param $line | ||
| 43 | + * @return void | ||
| 44 | + */ | ||
| 35 | private static function writeLogLine($line=NULL){ | 45 | private static function writeLogLine($line=NULL){ |
| 36 | -// echo('LOGFILE: '.realpath(self::getLogFile())); | ||
| 37 | if($line){ | 46 | if($line){ |
| 38 | $fp=fopen(self::getLogFile(),'a'); | 47 | $fp=fopen(self::getLogFile(),'a'); |
| 39 | fwrite($fp,$line."\n"); | 48 | fwrite($fp,$line."\n"); |
| @@ -46,7 +55,6 @@ class Clienttools_Syslog{ | @@ -46,7 +55,6 @@ class Clienttools_Syslog{ | ||
| 46 | * @return boolean | 55 | * @return boolean |
| 47 | */ | 56 | */ |
| 48 | private static function doErrorLogging(){ | 57 | private static function doErrorLogging(){ |
| 49 | -// $GLOBALS['default']['debugLevel']; //Another less secure way of finding the configured debugLevel | ||
| 50 | return KTConfig::getSingleton()->get('explorerCPSettings/debugLevel')=='error' || self::doDebugLogging(); | 58 | return KTConfig::getSingleton()->get('explorerCPSettings/debugLevel')=='error' || self::doDebugLogging(); |
| 51 | } | 59 | } |
| 52 | 60 | ||
| @@ -58,51 +66,80 @@ class Clienttools_Syslog{ | @@ -58,51 +66,80 @@ class Clienttools_Syslog{ | ||
| 58 | return KTConfig::getSingleton()->get('explorerCPSettings/debugLevel')=='debug'; | 66 | return KTConfig::getSingleton()->get('explorerCPSettings/debugLevel')=='debug'; |
| 59 | } | 67 | } |
| 60 | 68 | ||
| 69 | + /** | ||
| 70 | + * Store a line in the log file.. the message and a json string containing the data information will be stored | ||
| 71 | + * @param $user The logged in user | ||
| 72 | + * @param $location Information about the location from whence the function was called | ||
| 73 | + * @param $message The descriptive message explaining the debug data that follows | ||
| 74 | + * @param $data The debug data - this will be converted to a json string. | ||
| 75 | + * @return void | ||
| 76 | + */ | ||
| 61 | public static function logInfo($user,$location,$message,$data){ | 77 | public static function logInfo($user,$location,$message,$data){ |
| 62 | - list($usec, $sec) = explode(" ", microtime()); | ||
| 63 | - $usec=ceil($usec*1000); | ||
| 64 | - $entry=self::parseTemplate(self::$debugLogTemplate,array( | ||
| 65 | - 'date' =>date('Y-m-d'), | ||
| 66 | - 'time' =>date('h:i:s').':'.$usec, | ||
| 67 | - 'user' =>$user, | ||
| 68 | - 'session'=>session_id(), | ||
| 69 | - 'location'=>$location, | ||
| 70 | - 'debug_message'=>$message, | ||
| 71 | - 'debug_data'=>json_encode($data) | ||
| 72 | - )); | ||
| 73 | - | ||
| 74 | - self::writeLogLine($entry); | 78 | + if(self::doDebugLogging()){ |
| 79 | + list($usec, $sec) = explode(" ", microtime()); | ||
| 80 | + $usec=ceil($usec*1000); | ||
| 81 | + $entry=self::parseTemplate(self::$debugLogTemplate,array( | ||
| 82 | + 'date' =>date('Y-m-d'), | ||
| 83 | + 'time' =>date('h:i:s').':'.$usec, | ||
| 84 | + 'user' =>$user, | ||
| 85 | + 'session'=>session_id(), | ||
| 86 | + 'location'=>$location, | ||
| 87 | + 'debug_message'=>$message, | ||
| 88 | + 'debug_data'=>json_encode($data) | ||
| 89 | + )); | ||
| 90 | + | ||
| 91 | + self::writeLogLine($entry); | ||
| 92 | + } | ||
| 75 | } | 93 | } |
| 76 | 94 | ||
| 95 | + /** | ||
| 96 | + * Store a line in the log file.. A simple string to indicate a point in the software | ||
| 97 | + * @param $user The logged in user | ||
| 98 | + * @param $location Information about the location from whence the function was called | ||
| 99 | + * @param $message A string indicating a point reached in the software | ||
| 100 | + * @return void | ||
| 101 | + */ | ||
| 77 | public static function logTrace($user,$location,$message){ | 102 | public static function logTrace($user,$location,$message){ |
| 78 | - list($usec, $sec) = explode(" ", microtime()); | ||
| 79 | - $usec=ceil($usec*1000); | ||
| 80 | - $entry=self::parseTemplate(self::$traceLogTemplate,array( | ||
| 81 | - 'date' =>date('Y-m-d'), | ||
| 82 | - 'time' =>date('h:i:s').':'.$usec, | ||
| 83 | - 'user' =>$user, | ||
| 84 | - 'session'=>session_id(), | ||
| 85 | - 'location'=>$location, | ||
| 86 | - 'trace_message'=>$message, | ||
| 87 | - )); | ||
| 88 | - | ||
| 89 | - self::writeLogLine($entry); | 103 | + if(self::doDebugLogging()){ |
| 104 | + list($usec, $sec) = explode(" ", microtime()); | ||
| 105 | + $usec=ceil($usec*1000); | ||
| 106 | + $entry=self::parseTemplate(self::$traceLogTemplate,array( | ||
| 107 | + 'date' =>date('Y-m-d'), | ||
| 108 | + 'time' =>date('h:i:s').':'.$usec, | ||
| 109 | + 'user' =>$user, | ||
| 110 | + 'session'=>session_id(), | ||
| 111 | + 'location'=>$location, | ||
| 112 | + 'trace_message'=>$message, | ||
| 113 | + )); | ||
| 114 | + | ||
| 115 | + self::writeLogLine($entry); | ||
| 116 | + } | ||
| 90 | } | 117 | } |
| 91 | 118 | ||
| 119 | + /** | ||
| 120 | + * Store a line in the log file.. An Error log | ||
| 121 | + * @param $user The logged in user | ||
| 122 | + * @param $location Information about the location from whence the function was called | ||
| 123 | + * @param $detail A string providing information as to the context of the encountered error | ||
| 124 | + * @param $err The exception object - this will be serialized | ||
| 125 | + * @return void | ||
| 126 | + */ | ||
| 92 | public static function logError($user=NULL,$location=NULL,$detail=NULL,$err=NULL){ | 127 | public static function logError($user=NULL,$location=NULL,$detail=NULL,$err=NULL){ |
| 93 | - list($usec, $sec) = explode(" ", microtime()); | ||
| 94 | - $usec=ceil($usec*1000); | ||
| 95 | - $entry=self::parseTemplate(self::$errorLogTemplate,array( | ||
| 96 | - 'date' =>date('Y-m-d'), | ||
| 97 | - 'time' =>date('h:i:s').':'.$usec, | ||
| 98 | - 'user' =>$user, | ||
| 99 | - 'session'=>session_id(), | ||
| 100 | - 'location'=>$location, | ||
| 101 | - 'error_detail'=>json_encode($detail), | ||
| 102 | - 'error'=>json_encode($err), | ||
| 103 | - )); | ||
| 104 | - | ||
| 105 | - self::writeLogLine($entry); | 128 | + if(self::doErrorLogging()){ |
| 129 | + list($usec, $sec) = explode(" ", microtime()); | ||
| 130 | + $usec=ceil($usec*1000); | ||
| 131 | + $entry=self::parseTemplate(self::$errorLogTemplate,array( | ||
| 132 | + 'date' =>date('Y-m-d'), | ||
| 133 | + 'time' =>date('h:i:s').':'.$usec, | ||
| 134 | + 'user' =>$user, | ||
| 135 | + 'session'=>session_id(), | ||
| 136 | + 'location'=>$location, | ||
| 137 | + 'error_detail'=>json_encode($detail), | ||
| 138 | + 'error'=>json_encode($err), | ||
| 139 | + )); | ||
| 140 | + | ||
| 141 | + self::writeLogLine($entry); | ||
| 142 | + } | ||
| 106 | 143 | ||
| 107 | } | 144 | } |
| 108 | } | 145 | } |
webservice/clienttools/services/0.9/auth.php
| @@ -3,7 +3,7 @@ | @@ -3,7 +3,7 @@ | ||
| 3 | class auth extends client_service { | 3 | class auth extends client_service { |
| 4 | 4 | ||
| 5 | public function login(){ | 5 | public function login(){ |
| 6 | - $this->logTrace((__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); | 6 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 7 | $params=$this->AuthInfo; | 7 | $params=$this->AuthInfo; |
| 8 | 8 | ||
| 9 | $username=$params['user']; | 9 | $username=$params['user']; |
| @@ -72,7 +72,7 @@ class auth extends client_service { | @@ -72,7 +72,7 @@ class auth extends client_service { | ||
| 72 | } | 72 | } |
| 73 | 73 | ||
| 74 | public function japiLogin(){ | 74 | public function japiLogin(){ |
| 75 | - $this->logTrace((__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); | 75 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 76 | global $default; | 76 | global $default; |
| 77 | 77 | ||
| 78 | $user=$this->KT->get_user_object_by_username($this->AuthInfo['user']); | 78 | $user=$this->KT->get_user_object_by_username($this->AuthInfo['user']); |
| @@ -84,7 +84,7 @@ class auth extends client_service { | @@ -84,7 +84,7 @@ class auth extends client_service { | ||
| 84 | } | 84 | } |
| 85 | 85 | ||
| 86 | public function pickup_session(){ | 86 | public function pickup_session(){ |
| 87 | - $this->logTrace((__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); | 87 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 88 | $params=$this->AuthInfo; | 88 | $params=$this->AuthInfo; |
| 89 | $app_type=$params['appType']; | 89 | $app_type=$params['appType']; |
| 90 | $session_id=$params['session']; | 90 | $session_id=$params['session']; |
| @@ -101,7 +101,7 @@ class auth extends client_service { | @@ -101,7 +101,7 @@ class auth extends client_service { | ||
| 101 | 101 | ||
| 102 | 102 | ||
| 103 | public function ping(){ | 103 | public function ping(){ |
| 104 | - $this->logTrace((__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); | 104 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 105 | global $default; | 105 | global $default; |
| 106 | $user=$this->KT->get_user_object_by_username($this->AuthInfo['user']); | 106 | $user=$this->KT->get_user_object_by_username($this->AuthInfo['user']); |
| 107 | $versions=$this->handler->getServerVersions(); | 107 | $versions=$this->handler->getServerVersions(); |
| @@ -124,19 +124,19 @@ class auth extends client_service { | @@ -124,19 +124,19 @@ class auth extends client_service { | ||
| 124 | } | 124 | } |
| 125 | 125 | ||
| 126 | function logout($params){ | 126 | function logout($params){ |
| 127 | - $this->logTrace((__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); | 127 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 128 | $params=$this->AuthInfo; | 128 | $params=$this->AuthInfo; |
| 129 | $app_type=$params['appType']; | 129 | $app_type=$params['appType']; |
| 130 | $session_id=$params['session']; | 130 | $session_id=$params['session']; |
| 131 | $ip=$_SERVER['REMOTE_ADDR']; | 131 | $ip=$_SERVER['REMOTE_ADDR']; |
| 132 | 132 | ||
| 133 | $session=$this->KT->get_session(); | 133 | $session=$this->KT->get_session(); |
| 134 | - $this->logInfo((__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Logout Session Object (From KT)',$session); | 134 | + $this->logInfo((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Logout Session Object (From KT)',$session); |
| 135 | 135 | ||
| 136 | if(get_class($session)!='KTAPI_UserSession'){ | 136 | if(get_class($session)!='KTAPI_UserSession'){ |
| 137 | $session = $this->KT->get_active_session($session_id, $ip, $app_type); | 137 | $session = $this->KT->get_active_session($session_id, $ip, $app_type); |
| 138 | } | 138 | } |
| 139 | - $this->logInfo((__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Logout Session Object (To Logout)',$session); | 139 | + $this->logInfo((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Logout Session Object (To Logout)',$session); |
| 140 | 140 | ||
| 141 | if (PEAR::isError($session)){ | 141 | if (PEAR::isError($session)){ |
| 142 | return false; | 142 | return false; |
webservice/clienttools/services/0.9/kt.php
| @@ -8,7 +8,7 @@ class kt extends client_service { | @@ -8,7 +8,7 @@ class kt extends client_service { | ||
| 8 | * | 8 | * |
| 9 | */ | 9 | */ |
| 10 | function get_languages($passthru = false) { | 10 | function get_languages($passthru = false) { |
| 11 | - $this->logTrace ( __CLASS__ . '::' . __METHOD__ . '(' . __FILE__ . ' ' . __LINE__, 'Enter Function' ); | 11 | + $this->logTrace ((__METHOD__.'('.__FILE__.' '.__LINE__.')'), 'Enter Function' ); |
| 12 | global $default; | 12 | global $default; |
| 13 | $oReg = & KTi18nregistry::getSingleton (); | 13 | $oReg = & KTi18nregistry::getSingleton (); |
| 14 | $aRegisteredLangs = $oReg->geti18nLanguages ( 'knowledgeTree' ); | 14 | $aRegisteredLangs = $oReg->geti18nLanguages ( 'knowledgeTree' ); |
| @@ -28,13 +28,13 @@ class kt extends client_service { | @@ -28,13 +28,13 @@ class kt extends client_service { | ||
| 28 | } | 28 | } |
| 29 | 29 | ||
| 30 | function get_rootfolder_detail($params) { | 30 | function get_rootfolder_detail($params) { |
| 31 | - $this->logTrace ( __CLASS__ . '::' . __METHOD__ . '(' . __FILE__ . ' ' . __LINE__, 'Enter Function' ); | 31 | + $this->logTrace ((__METHOD__.'('.__FILE__.' '.__LINE__.')'), 'Enter Function' ); |
| 32 | $params ['folderId'] = '1'; | 32 | $params ['folderId'] = '1'; |
| 33 | $this->get_folder_detail ( $params ); | 33 | $this->get_folder_detail ( $params ); |
| 34 | } | 34 | } |
| 35 | 35 | ||
| 36 | function get_folder_detail($params) { | 36 | function get_folder_detail($params) { |
| 37 | - $this->logTrace ( __CLASS__ . '::' . __METHOD__ . '(' . __FILE__ . ' ' . __LINE__, 'Enter Function' ); | 37 | + $this->logTrace ((__METHOD__.'('.__FILE__.' '.__LINE__.')'), 'Enter Function' ); |
| 38 | if (isset ( $params ['node'] ) && ! isset ( $params ['folderId'] )) { | 38 | if (isset ( $params ['node'] ) && ! isset ( $params ['folderId'] )) { |
| 39 | $params ['node'] = split ( '_', $params ['node'] ); | 39 | $params ['node'] = split ( '_', $params ['node'] ); |
| 40 | $params ['folderId'] = $params ['node'] [1]; | 40 | $params ['folderId'] = $params ['node'] [1]; |
| @@ -94,7 +94,7 @@ class kt extends client_service { | @@ -94,7 +94,7 @@ class kt extends client_service { | ||
| 94 | } | 94 | } |
| 95 | 95 | ||
| 96 | function get_folder_contents($params) { | 96 | function get_folder_contents($params) { |
| 97 | - $this->logTrace ( __CLASS__ . '::' . __METHOD__ . '(' . __FILE__ . ' ' . __LINE__, 'Enter Function' ); | 97 | + $this->logTrace ((__METHOD__.'('.__FILE__.' '.__LINE__.')'), 'Enter Function' ); |
| 98 | $kt = &$this->KT; | 98 | $kt = &$this->KT; |
| 99 | 99 | ||
| 100 | $params ['control'] = 'F_'; | 100 | $params ['control'] = 'F_'; |
| @@ -119,7 +119,7 @@ class kt extends client_service { | @@ -119,7 +119,7 @@ class kt extends client_service { | ||
| 119 | * @return array | 119 | * @return array |
| 120 | */ | 120 | */ |
| 121 | function get_folder_contents_for_grid($arr) { | 121 | function get_folder_contents_for_grid($arr) { |
| 122 | - $this->logTrace ( __CLASS__ . '::' . __METHOD__ . '(' . __FILE__ . ' ' . __LINE__, 'Enter Function' ); | 122 | + $this->logTrace ((__METHOD__.'('.__FILE__.' '.__LINE__.')'), 'Enter Function' ); |
| 123 | $kt = &$this->KT; | 123 | $kt = &$this->KT; |
| 124 | 124 | ||
| 125 | $arr ['control'] = 'F_'; | 125 | $arr ['control'] = 'F_'; |
| @@ -144,7 +144,7 @@ class kt extends client_service { | @@ -144,7 +144,7 @@ class kt extends client_service { | ||
| 144 | } | 144 | } |
| 145 | 145 | ||
| 146 | private function _processListing($listing, $type, $arr) { | 146 | private function _processListing($listing, $type, $arr) { |
| 147 | - $this->logTrace ( __CLASS__ . '::' . __METHOD__ . '(' . __FILE__ . ' ' . __LINE__, 'Enter Function' ); | 147 | + $this->logTrace ((__METHOD__.'('.__FILE__.' '.__LINE__.')'), 'Enter Function' ); |
| 148 | $result = array (); | 148 | $result = array (); |
| 149 | $methodToIncludeItem = '_processItemInclusion_' . $type; | 149 | $methodToIncludeItem = '_processItemInclusion_' . $type; |
| 150 | 150 | ||
| @@ -244,12 +244,12 @@ class kt extends client_service { | @@ -244,12 +244,12 @@ class kt extends client_service { | ||
| 244 | } | 244 | } |
| 245 | 245 | ||
| 246 | private function _processItemInclusion_folderContents($item, $class, $qtip) { | 246 | private function _processItemInclusion_folderContents($item, $class, $qtip) { |
| 247 | - $this->logTrace ( __CLASS__ . '::' . __METHOD__ . '(' . __FILE__ . ' ' . __LINE__, 'Enter Function' ); | 247 | + $this->logTrace ((__METHOD__.'('.__FILE__.' '.__LINE__.')'), 'Enter Function' ); |
| 248 | return array ('text' => htmlspecialchars ( $item ['title'] ), 'originaltext' => $item ['title'], 'id' => ($item ['item_type'] == 'F' ? $item ['item_type'] . "_" : "") . $item ['id'], 'filename' => $item ['filename'], 'cls' => $class, 'leaf' => ($item ['item_type'] == 'D'), 'document_type' => $item ['document_type'], 'item_type' => $item ['item_type'], 'permissions' => $item ['permissions'], 'content_id' => $item ['content_id'], 'checked_out_by' => $item ['checked_out_by'], 'qtip' => $qtip ); | 248 | return array ('text' => htmlspecialchars ( $item ['title'] ), 'originaltext' => $item ['title'], 'id' => ($item ['item_type'] == 'F' ? $item ['item_type'] . "_" : "") . $item ['id'], 'filename' => $item ['filename'], 'cls' => $class, 'leaf' => ($item ['item_type'] == 'D'), 'document_type' => $item ['document_type'], 'item_type' => $item ['item_type'], 'permissions' => $item ['permissions'], 'content_id' => $item ['content_id'], 'checked_out_by' => $item ['checked_out_by'], 'qtip' => $qtip ); |
| 249 | } | 249 | } |
| 250 | 250 | ||
| 251 | private function _processItemInclusion_search($item, $class, $qtip) { | 251 | private function _processItemInclusion_search($item, $class, $qtip) { |
| 252 | - $this->logTrace ( __CLASS__ . '::' . __METHOD__ . '(' . __FILE__ . ' ' . __LINE__, 'Enter Function' ); | 252 | + $this->logTrace ((__METHOD__.'('.__FILE__.' '.__LINE__.')'), 'Enter Function' ); |
| 253 | if ($item ['filesize'] == 'n/a') { | 253 | if ($item ['filesize'] == 'n/a') { |
| 254 | $item ['filesize'] = - 1; | 254 | $item ['filesize'] = - 1; |
| 255 | } | 255 | } |
| @@ -257,7 +257,7 @@ class kt extends client_service { | @@ -257,7 +257,7 @@ class kt extends client_service { | ||
| 257 | } | 257 | } |
| 258 | 258 | ||
| 259 | private function _processItemInclusion_grid($item, $class, $qtip) { | 259 | private function _processItemInclusion_grid($item, $class, $qtip) { |
| 260 | - $this->logTrace ( __CLASS__ . '::' . __METHOD__ . '(' . __FILE__ . ' ' . __LINE__, 'Enter Function' ); | 260 | + $this->logTrace ((__METHOD__.'('.__FILE__.' '.__LINE__.')'), 'Enter Function' ); |
| 261 | //var_dump($item); | 261 | //var_dump($item); |
| 262 | 262 | ||
| 263 | 263 | ||
| @@ -269,7 +269,7 @@ class kt extends client_service { | @@ -269,7 +269,7 @@ class kt extends client_service { | ||
| 269 | } | 269 | } |
| 270 | 270 | ||
| 271 | public function get_metadata($params) { | 271 | public function get_metadata($params) { |
| 272 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 272 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 273 | $kt = &$this->KT; | 273 | $kt = &$this->KT; |
| 274 | 274 | ||
| 275 | if (substr ( $params ['document_id'], 0, 2 ) == 'D_') { | 275 | if (substr ( $params ['document_id'], 0, 2 ) == 'D_') { |
| @@ -351,7 +351,7 @@ class kt extends client_service { | @@ -351,7 +351,7 @@ class kt extends client_service { | ||
| 351 | } | 351 | } |
| 352 | 352 | ||
| 353 | public function get_documenttypes($params) { | 353 | public function get_documenttypes($params) { |
| 354 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 354 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 355 | 355 | ||
| 356 | $kt = &$this->KT; | 356 | $kt = &$this->KT; |
| 357 | 357 | ||
| @@ -394,7 +394,7 @@ class kt extends client_service { | @@ -394,7 +394,7 @@ class kt extends client_service { | ||
| 394 | * @param unknown_type $params | 394 | * @param unknown_type $params |
| 395 | */ | 395 | */ |
| 396 | function download_document($params, $returnResult = false){ | 396 | function download_document($params, $returnResult = false){ |
| 397 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 397 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 398 | 398 | ||
| 399 | $kt = &$this->KT; | 399 | $kt = &$this->KT; |
| 400 | $params ['session_id'] = $params ['session_id'] ? $params ['session_id'] : $this->AuthInfo ['session']; | 400 | $params ['session_id'] = $params ['session_id'] ? $params ['session_id'] : $this->AuthInfo ['session']; |
| @@ -461,7 +461,7 @@ class kt extends client_service { | @@ -461,7 +461,7 @@ class kt extends client_service { | ||
| 461 | * @param unknown_type $params | 461 | * @param unknown_type $params |
| 462 | */ | 462 | */ |
| 463 | public function download_multiple_documents($params) { | 463 | public function download_multiple_documents($params) { |
| 464 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 464 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 465 | $response = array (); | 465 | $response = array (); |
| 466 | foreach ( $params ['documents'] as $docId ) { | 466 | foreach ( $params ['documents'] as $docId ) { |
| 467 | $ret = $this->download_document ( array ('document_id' => $docId, 'app_type' => $params ['app_type'], 'multipart' => $params ['multipart'] ), true ); | 467 | $ret = $this->download_document ( array ('document_id' => $docId, 'app_type' => $params ['app_type'], 'multipart' => $params ['multipart'] ), true ); |
| @@ -483,7 +483,7 @@ class kt extends client_service { | @@ -483,7 +483,7 @@ class kt extends client_service { | ||
| 483 | * | 483 | * |
| 484 | */ | 484 | */ |
| 485 | function checkout_document($params) { | 485 | function checkout_document($params) { |
| 486 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 486 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 487 | $responseType = 'kt_response'; | 487 | $responseType = 'kt_response'; |
| 488 | $kt = &$this->KT; | 488 | $kt = &$this->KT; |
| 489 | 489 | ||
| @@ -523,7 +523,7 @@ class kt extends client_service { | @@ -523,7 +523,7 @@ class kt extends client_service { | ||
| 523 | * @param array $params | 523 | * @param array $params |
| 524 | */ | 524 | */ |
| 525 | function checkin_document($params) { | 525 | function checkin_document($params) { |
| 526 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 526 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 527 | $session_id = $this->AuthInfo ['session']; | 527 | $session_id = $this->AuthInfo ['session']; |
| 528 | $document_id = $params ['document_id']; | 528 | $document_id = $params ['document_id']; |
| 529 | $filename = $params ['filename']; | 529 | $filename = $params ['filename']; |
| @@ -569,7 +569,7 @@ class kt extends client_service { | @@ -569,7 +569,7 @@ class kt extends client_service { | ||
| 569 | * @param unknown_type $arr | 569 | * @param unknown_type $arr |
| 570 | */ | 570 | */ |
| 571 | function add_document_with_metadata($arr) { | 571 | function add_document_with_metadata($arr) { |
| 572 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 572 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 573 | $session_id = $arr ['session_id']; | 573 | $session_id = $arr ['session_id']; |
| 574 | //error_reporting(E_ALL); | 574 | //error_reporting(E_ALL); |
| 575 | $metadata = array (); | 575 | $metadata = array (); |
| @@ -625,7 +625,7 @@ class kt extends client_service { | @@ -625,7 +625,7 @@ class kt extends client_service { | ||
| 625 | } | 625 | } |
| 626 | 626 | ||
| 627 | function create_empty_upload_file($params) { | 627 | function create_empty_upload_file($params) { |
| 628 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 628 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 629 | $config = KTConfig::getSingleton (); | 629 | $config = KTConfig::getSingleton (); |
| 630 | $this->addDebug ( 'KTConfig Singleton', $config ); | 630 | $this->addDebug ( 'KTConfig Singleton', $config ); |
| 631 | $uploadFolder = $config->get ( 'webservice/uploadDirectory' ); | 631 | $uploadFolder = $config->get ( 'webservice/uploadDirectory' ); |
| @@ -645,7 +645,7 @@ class kt extends client_service { | @@ -645,7 +645,7 @@ class kt extends client_service { | ||
| 645 | } | 645 | } |
| 646 | 646 | ||
| 647 | function get_all_client_policies() { | 647 | function get_all_client_policies() { |
| 648 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 648 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 649 | $config = KTConfig::getSingleton (); | 649 | $config = KTConfig::getSingleton (); |
| 650 | $this->addDebug ( 'KTConfig Singleton', $config ); | 650 | $this->addDebug ( 'KTConfig Singleton', $config ); |
| 651 | 651 | ||
| @@ -675,7 +675,7 @@ class kt extends client_service { | @@ -675,7 +675,7 @@ class kt extends client_service { | ||
| 675 | } | 675 | } |
| 676 | 676 | ||
| 677 | function get_all_explorer_policies() { | 677 | function get_all_explorer_policies() { |
| 678 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 678 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 679 | $config = KTConfig::getSingleton (); | 679 | $config = KTConfig::getSingleton (); |
| 680 | $this->addDebug ( 'KTConfig Singleton', $config ); | 680 | $this->addDebug ( 'KTConfig Singleton', $config ); |
| 681 | 681 | ||
| @@ -707,12 +707,12 @@ class kt extends client_service { | @@ -707,12 +707,12 @@ class kt extends client_service { | ||
| 707 | } | 707 | } |
| 708 | 708 | ||
| 709 | public function switchlang($params) { | 709 | public function switchlang($params) { |
| 710 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 710 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 711 | setcookie ( "kt_language", $params ['lang'], 2147483647, '/' ); | 711 | setcookie ( "kt_language", $params ['lang'], 2147483647, '/' ); |
| 712 | } | 712 | } |
| 713 | 713 | ||
| 714 | function add_document_params($params) { | 714 | function add_document_params($params) { |
| 715 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 715 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 716 | $folder_id = $params ['folder_id']; | 716 | $folder_id = $params ['folder_id']; |
| 717 | $title = $params ['title']; | 717 | $title = $params ['title']; |
| 718 | $filename = $params ['filename']; | 718 | $filename = $params ['filename']; |
| @@ -757,7 +757,7 @@ class kt extends client_service { | @@ -757,7 +757,7 @@ class kt extends client_service { | ||
| 757 | } | 757 | } |
| 758 | 758 | ||
| 759 | function delete_document($params) { | 759 | function delete_document($params) { |
| 760 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 760 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 761 | $session_id = $params ['session_id']; | 761 | $session_id = $params ['session_id']; |
| 762 | $document_id = $params ['document_id']; | 762 | $document_id = $params ['document_id']; |
| 763 | $reason = $params ['reason']; | 763 | $reason = $params ['reason']; |
| @@ -783,7 +783,7 @@ class kt extends client_service { | @@ -783,7 +783,7 @@ class kt extends client_service { | ||
| 783 | } | 783 | } |
| 784 | 784 | ||
| 785 | private function update_document_metadata($session_id, $document_id, $metadata, $application, $sysdata = null) { | 785 | private function update_document_metadata($session_id, $document_id, $metadata, $application, $sysdata = null) { |
| 786 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 786 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 787 | $this->addDebug ( 'update_document_metadata', 'entered update_document_metadata' ); | 787 | $this->addDebug ( 'update_document_metadata', 'entered update_document_metadata' ); |
| 788 | $kt = &$this->KT; | 788 | $kt = &$this->KT; |
| 789 | $responseType = 'kt_document_detail'; | 789 | $responseType = 'kt_document_detail'; |
| @@ -807,7 +807,7 @@ class kt extends client_service { | @@ -807,7 +807,7 @@ class kt extends client_service { | ||
| 807 | } | 807 | } |
| 808 | 808 | ||
| 809 | function get_client_policy($arr) { | 809 | function get_client_policy($arr) { |
| 810 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 810 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 811 | $policy_name = $arr ['policy_name']; | 811 | $policy_name = $arr ['policy_name']; |
| 812 | 812 | ||
| 813 | $config = KTConfig::getSingleton (); | 813 | $config = KTConfig::getSingleton (); |
| @@ -823,7 +823,7 @@ class kt extends client_service { | @@ -823,7 +823,7 @@ class kt extends client_service { | ||
| 823 | } | 823 | } |
| 824 | 824 | ||
| 825 | function search($arr) { | 825 | function search($arr) { |
| 826 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 826 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 827 | $kt = &$this->KT; | 827 | $kt = &$this->KT; |
| 828 | 828 | ||
| 829 | $listing = processSearchExpression ( "(GeneralText contains \"" . $arr ['query'] . "\")" ); | 829 | $listing = processSearchExpression ( "(GeneralText contains \"" . $arr ['query'] . "\")" ); |
| @@ -843,7 +843,7 @@ class kt extends client_service { | @@ -843,7 +843,7 @@ class kt extends client_service { | ||
| 843 | } | 843 | } |
| 844 | 844 | ||
| 845 | public function update_metadata($arr) { | 845 | public function update_metadata($arr) { |
| 846 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 846 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 847 | $metadata = array (); | 847 | $metadata = array (); |
| 848 | $meta = $arr ['metadata']; | 848 | $meta = $arr ['metadata']; |
| 849 | 849 | ||
| @@ -928,7 +928,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -928,7 +928,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 928 | } | 928 | } |
| 929 | 929 | ||
| 930 | function check_document_title($arr) { | 930 | function check_document_title($arr) { |
| 931 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 931 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 932 | $kt = &$this->KT; | 932 | $kt = &$this->KT; |
| 933 | 933 | ||
| 934 | $folder = $kt->get_folder_by_id ( $arr ['folder_id'] ); | 934 | $folder = $kt->get_folder_by_id ( $arr ['folder_id'] ); |
| @@ -948,7 +948,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -948,7 +948,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 948 | } | 948 | } |
| 949 | 949 | ||
| 950 | function cancel_checkout($params) { | 950 | function cancel_checkout($params) { |
| 951 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 951 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 952 | $kt = &$this->KT; | 952 | $kt = &$this->KT; |
| 953 | 953 | ||
| 954 | $document = &$kt->get_document_by_id ( $params ['document_id'] ); | 954 | $document = &$kt->get_document_by_id ( $params ['document_id'] ); |
| @@ -967,7 +967,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -967,7 +967,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 967 | } | 967 | } |
| 968 | 968 | ||
| 969 | function get_transaction_history($params) { | 969 | function get_transaction_history($params) { |
| 970 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 970 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 971 | $kt = &$this->KT; | 971 | $kt = &$this->KT; |
| 972 | 972 | ||
| 973 | $document = &$kt->get_document_by_id ( $params ['document_id'] ); | 973 | $document = &$kt->get_document_by_id ( $params ['document_id'] ); |
| @@ -985,7 +985,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -985,7 +985,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 985 | } | 985 | } |
| 986 | 986 | ||
| 987 | public function get_users_groups($params) { | 987 | public function get_users_groups($params) { |
| 988 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 988 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 989 | $kt = &$this->KT; | 989 | $kt = &$this->KT; |
| 990 | $query = $params ['query']; | 990 | $query = $params ['query']; |
| 991 | //$start=$params['start']; | 991 | //$start=$params['start']; |
| @@ -1013,7 +1013,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -1013,7 +1013,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 1013 | } | 1013 | } |
| 1014 | 1014 | ||
| 1015 | function send_email($params) { | 1015 | function send_email($params) { |
| 1016 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 1016 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 1017 | $kt = &$this->KT; | 1017 | $kt = &$this->KT; |
| 1018 | 1018 | ||
| 1019 | $message = $params ['message']; | 1019 | $message = $params ['message']; |
| @@ -1066,7 +1066,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -1066,7 +1066,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 1066 | } | 1066 | } |
| 1067 | 1067 | ||
| 1068 | function is_latest_version($params) { | 1068 | function is_latest_version($params) { |
| 1069 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 1069 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 1070 | $kt = &$this->KT; | 1070 | $kt = &$this->KT; |
| 1071 | 1071 | ||
| 1072 | $documentId = $params ['document_id']; | 1072 | $documentId = $params ['document_id']; |
| @@ -1079,7 +1079,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -1079,7 +1079,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 1079 | } | 1079 | } |
| 1080 | 1080 | ||
| 1081 | function check_permission($params) { | 1081 | function check_permission($params) { |
| 1082 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 1082 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 1083 | $kt = &$this->KT; | 1083 | $kt = &$this->KT; |
| 1084 | 1084 | ||
| 1085 | $user = $kt->get_user (); | 1085 | $user = $kt->get_user (); |
| @@ -1096,7 +1096,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -1096,7 +1096,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 1096 | } | 1096 | } |
| 1097 | 1097 | ||
| 1098 | function copydocument($params) { | 1098 | function copydocument($params) { |
| 1099 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 1099 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 1100 | $kt = &$this->KT; | 1100 | $kt = &$this->KT; |
| 1101 | 1101 | ||
| 1102 | $response = $kt->copy_document ( $params ['documentid'], $params ['destfolderid'], $params ['reason'] ); | 1102 | $response = $kt->copy_document ( $params ['documentid'], $params ['destfolderid'], $params ['reason'] ); |
| @@ -1110,7 +1110,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -1110,7 +1110,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 1110 | } | 1110 | } |
| 1111 | 1111 | ||
| 1112 | function movedocument($params) { | 1112 | function movedocument($params) { |
| 1113 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 1113 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 1114 | $kt = $this->KT; | 1114 | $kt = $this->KT; |
| 1115 | 1115 | ||
| 1116 | $response = $kt->move_document ( $params ['documentid'], $params ['destfolderid'], $params ['reason'] ); | 1116 | $response = $kt->move_document ( $params ['documentid'], $params ['destfolderid'], $params ['reason'] ); |
| @@ -1125,7 +1125,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -1125,7 +1125,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 1125 | } | 1125 | } |
| 1126 | 1126 | ||
| 1127 | function copyfolder($params) { | 1127 | function copyfolder($params) { |
| 1128 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 1128 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 1129 | $kt = &$this->KT; | 1129 | $kt = &$this->KT; |
| 1130 | 1130 | ||
| 1131 | $response = $kt->copy_folder ( $params ['sourcefolderid'], $params ['destfolderid'], $params ['reason'] ); | 1131 | $response = $kt->copy_folder ( $params ['sourcefolderid'], $params ['destfolderid'], $params ['reason'] ); |
| @@ -1140,7 +1140,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -1140,7 +1140,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 1140 | } | 1140 | } |
| 1141 | 1141 | ||
| 1142 | function movefolder($params) { | 1142 | function movefolder($params) { |
| 1143 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 1143 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 1144 | $kt = &$this->KT; | 1144 | $kt = &$this->KT; |
| 1145 | 1145 | ||
| 1146 | $response = $kt->move_folder ( $params ['sourcefolderid'], $params ['destfolderid'], $params ['reason'] ); | 1146 | $response = $kt->move_folder ( $params ['sourcefolderid'], $params ['destfolderid'], $params ['reason'] ); |
| @@ -1154,7 +1154,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -1154,7 +1154,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 1154 | } | 1154 | } |
| 1155 | 1155 | ||
| 1156 | function renamefolder($params) { | 1156 | function renamefolder($params) { |
| 1157 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 1157 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 1158 | $kt = &$this->KT; | 1158 | $kt = &$this->KT; |
| 1159 | 1159 | ||
| 1160 | $response = $kt->rename_folder ( $params ['currentfolderid'], $params ['newname'] ); | 1160 | $response = $kt->rename_folder ( $params ['currentfolderid'], $params ['newname'] ); |
| @@ -1168,7 +1168,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -1168,7 +1168,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 1168 | } | 1168 | } |
| 1169 | 1169 | ||
| 1170 | function addfolder($params) { | 1170 | function addfolder($params) { |
| 1171 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 1171 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 1172 | $kt = &$this->KT; | 1172 | $kt = &$this->KT; |
| 1173 | $this->addDebug ( 'parameters', $params ); | 1173 | $this->addDebug ( 'parameters', $params ); |
| 1174 | $response = $kt->create_folder ( $params ['currentfolderid'], $params ['newname'] ); | 1174 | $response = $kt->create_folder ( $params ['currentfolderid'], $params ['newname'] ); |
| @@ -1177,7 +1177,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -1177,7 +1177,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 1177 | } | 1177 | } |
| 1178 | 1178 | ||
| 1179 | function deletefolder($params) { | 1179 | function deletefolder($params) { |
| 1180 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 1180 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 1181 | $kt = &$this->KT; | 1181 | $kt = &$this->KT; |
| 1182 | 1182 | ||
| 1183 | $response = $kt->delete_folder ( $params ['folderid'], $params ['reason'] ); | 1183 | $response = $kt->delete_folder ( $params ['folderid'], $params ['reason'] ); |
| @@ -1191,7 +1191,7 @@ Fatal error: Cannot unset string offsets in on line 981 | @@ -1191,7 +1191,7 @@ Fatal error: Cannot unset string offsets in on line 981 | ||
| 1191 | } | 1191 | } |
| 1192 | 1192 | ||
| 1193 | function candeletefolder($arr) { | 1193 | function candeletefolder($arr) { |
| 1194 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 1194 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 1195 | $kt = &$this->KT; | 1195 | $kt = &$this->KT; |
| 1196 | 1196 | ||
| 1197 | $folder = &$kt->get_folder_by_id ( $arr ['folderid'] ); | 1197 | $folder = &$kt->get_folder_by_id ( $arr ['folderid'] ); |
webservice/clienttools/services/0.9/server.php
| 1 | <?php | 1 | <?php |
| 2 | class server extends client_service { | 2 | class server extends client_service { |
| 3 | public function status(){ | 3 | public function status(){ |
| 4 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 4 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 5 | $this->setResponse(array('online'=>true)); | 5 | $this->setResponse(array('online'=>true)); |
| 6 | } | 6 | } |
| 7 | 7 | ||
| 8 | public function ping(){ | 8 | public function ping(){ |
| 9 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 9 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 10 | $this->addResponse('pong',time()); | 10 | $this->addResponse('pong',time()); |
| 11 | } | 11 | } |
| 12 | 12 | ||
| 13 | public function getToken(){ | 13 | public function getToken(){ |
| 14 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 14 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 15 | 15 | ||
| 16 | } | 16 | } |
| 17 | 17 | ||
| 18 | public function phpInfo(){ | 18 | public function phpInfo(){ |
| 19 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 19 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 20 | ob_start(); | 20 | ob_start(); |
| 21 | phpinfo(); | 21 | phpinfo(); |
| 22 | $this->addResponse('phpinfo',ob_get_clean()); | 22 | $this->addResponse('phpinfo',ob_get_clean()); |
webservice/clienttools/standardservices/system.php
| 1 | <?php | 1 | <?php |
| 2 | class system extends client_service{ | 2 | class system extends client_service{ |
| 3 | public function checkVersion(){ | 3 | public function checkVersion(){ |
| 4 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 4 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 5 | global $default; | 5 | global $default; |
| 6 | $user=$this->KT->get_user_object_by_username($this->AuthInfo['user']); | 6 | $user=$this->KT->get_user_object_by_username($this->AuthInfo['user']); |
| 7 | $versions=$this->handler->getServerVersions(); | 7 | $versions=$this->handler->getServerVersions(); |
| @@ -20,14 +20,14 @@ class system extends client_service{ | @@ -20,14 +20,14 @@ class system extends client_service{ | ||
| 20 | 20 | ||
| 21 | ); | 21 | ); |
| 22 | $this->setResponse($ret); | 22 | $this->setResponse($ret); |
| 23 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Exit Function'); | 23 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Exit Function'); |
| 24 | return true; | 24 | return true; |
| 25 | } | 25 | } |
| 26 | 26 | ||
| 27 | public function jsondecode($params){ | 27 | public function jsondecode($params){ |
| 28 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Enter Function'); | 28 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Enter Function'); |
| 29 | $this->setResponse(@json_decode(trim($params['code']))); | 29 | $this->setResponse(@json_decode(trim($params['code']))); |
| 30 | - $this->logTrace(__CLASS__.'::'.__METHOD__.'('.__FILE__.' '.__LINE__,'Exit Function'); | 30 | + $this->logTrace((__METHOD__.'('.__FILE__.' '.__LINE__.')'),'Exit Function'); |
| 31 | } | 31 | } |
| 32 | } | 32 | } |
| 33 | 33 |