==== XML ==== ==== PHP ==== /** * Put user contact * @param array $contact contact array * @return array */ function rpcf_put_user_contact ( $contact ) { global $config; //if ( $config->getDebugMode() ) { // $this->writeDebugLog(__METHOD__.", user_id = ".$user_id); //} $ret=array(); if (!$this->connection->urfa_call( 0x2022) ) { print "Error calling function ". __FUNCTION__ ."\n"; return FALSE; } $packet = $this->connection->getPacket(); $packet->DataSetInt($contact['id']); $packet->DataSetInt($contact['user_id']); $packet->DataSetString($contact['person']); $packet->DataSetString($contact['descr']); $packet->DataSetString($contact['contact']); $packet->DataSetString($contact['email']); //$packet->DataSetInt($contact['email_notify']); $packet->DataSetInt(1); $packet->DataSetString($contact['short_name']); $packet->DataSetString($contact['birthday']); $packet->DataSetInt($contact['id_exec_man']); if ( $config->getDebugMode() ) { $this->writeDebugLog(__METHOD__.", packet = ".var_export($packet, true)); } $this->connection->urfa_send_param($packet); //$x = $this->connection->urfa_get_data(); if ( $config->getDebugMode() ) { $this->writeDebugLog(__METHOD__.", x = ".var_export($x, true)); } return true; } тут я использовал свои метода writeDebugLog(), $config->getDebugMode(); - можно закомментировать